Skip to content

☂️ Move the material and cupertino packages outside of Flutter #101479

Open
1 of 4 issues completed
Open

Description

@nikitadol

This issue tracks the work to formally decouple the material and cupertino libraries from the core Flutter framework and establish them as standalone, first-party packages on pub.dev.

➡️ 📄 Read more about our plan. ⬅️

This strategic transition will make Flutter's core lighter and more flexible, accelerate design library updates, and give developers more control over their app's dependencies.

The work will be managed through a deliberate, three-phased approach to ensure a stable and predictable migration for the entire ecosystem.

The sub-issues listed below track the specific tasks for each phase of this project.

📣 To provide feedback:


OP

Use case

  • Long update cycle
  • To get the new version - you need to update the version of Flutter
  • Random imports
  • Components for other platforms are separate from Flutter (fluent, macos_ui, yaru, ...)

Proposal

Move material and cupertino packages from Flutter

It can be done along with this issue (#91605)

Update 04/18/25

Link to proposal by @MaherSafadii with examples.

Activity

  1. maheshj01 commented on Apr 7, 2022

    @maheshj01
    Member

    Hi @nikitadol, Thanks for filing the issue. If I understand it right moving material and Cupertino outside of flutter means, the flutter SDK wouldn't have any of the default material and Cupertino widgets, unless they are explicitly imported from pub.
    I believe doing so would lead to inconsistency and duplication of code across both packages.

    Components for other platforms are separate from Flutter (fluent, macos_ui, yaru, ...)

    the packages that you linked are third-party packages so they are not part of the framework.

    Labeling this issue for further thoughts from the team.

    cc: @rami-a

    Edit: The inconsistency and duplication I was referring to is the code which is being reused across both material and cupertino

  2. added
    frameworkflutter/packages/flutter repository. See also f: labels.
    p: material_uimaterial_ui package in flutter/packages
    p: cupertino_uicupertino_ui package in flutter/packages
    c: proposalA detailed proposal for a change to Flutter
    and removed
    in triagePresently being triaged by the triage team
    on Apr 7, 2022
  3. nikitadol commented on Apr 7, 2022

    @nikitadol
    Author

    I believe doing so would lead to inconsistency and duplication of code across both packages.

    The material package depends on cupertino - I do not quite understand what the problem will be

  4. a-eniou-pvotal commented on Apr 20, 2022

    @a-eniou-pvotal

    I think about this case and I found it is a good idea but in the long-term, it will lead to a fragmented community
    Like a company uses AmazonButton and a different company using AppleButton so changing a company to the next company that uses different UI names and parameters will be a bad experience

  5. LasseRosenow commented on Apr 21, 2022

    @LasseRosenow
    Contributor

    I think about this case and I found it is a good idea but in the long-term, it will lead to a fragmented community Like a company uses AmazonButton and a different company using AppleButton so changing a company to the next company that uses different UI names and parameters will be a bad experience

    Except that scenario is very unlikely to happen, why would a company change its flutter app to use a totally different design system? Also right now this is not possible either, as cupertino and material have different widgets as well.

    There are community efforts to bring together multiple design system in a platform agnostic way i think they are called platform-widgets or something like that.

    Thanks for filing the issue. If I understand it right moving material and Cupertino outside of flutter means, the flutter SDK wouldn't have any of the default material and Cupertino widgets, unless they are explicitly imported from pub.
    I believe doing so would lead to inconsistency and duplication of code across both packages.

    I think not. I think the best Idea would be to have basic stuff inside flutter, like RawScrollbar etc. But everything that is different should be in a different package. Similar to how it is right now, but just that the package does not live inside flutter, but outside, which would have multiple advantages:

    • If you don't use material or cupertino, but something like yaru or fluent, you are no longer annoyed by autocompletion that suggests you to use material or cupertino buttons. Sounds simple, but is a really bad user experience
    • The material / cupertino library can have easier breaking changes without needing tons of backwards compatibility by just increasing the major version number is something like material 3 or in the future perhaps material 4 is released. The developer does not need to update the package but can still upgrade flutter without needing to migrate the whole application to a major design system change
    • Flutter becomes more like a better html / css kind of framework but without the html and css of course :D. Which is something I would like very much to happen. To have flutter just be the framework without making any assumptions as to what kind of design you want to implement. This would also make it more obvious to newcomers that flutter is not just to make material / cupertino apps.
  6. LasseRosenow commented on Apr 21, 2022

    @LasseRosenow
    Contributor

    I think in general flutter has a very weird approach with including a gui library within the framework. It is very unusual.

    Competing modern frameworks don't do it either (I know this is a weak argument, but I wanted to mention it :D). Like react or react native or lit or vue.js etc. They all are just frameworks that give you a way to implement what ever design you want in html and css, which is similar to flutters basic widgets, but there are external web component libraries that you can use for example that will give you some sort of design system. And you can choose depending on what you want to do. I think this is how it should be.

  7. n7trd commented on Apr 28, 2022

    @n7trd

    I'm also in favor of removing specific ui libraries (material, cupertino) out of the "core" framework.

    • Its better for maintenance if material & cupertino are not tied to the core framework as pointed out above (backwards compatibility, breaking changes, update cycle). See the discussion ☂️ Bring Material 3 to Flutter #91605
    • It gives tribute to the variety of other component libraries (flame-engine, fluent, macos_ui, yaru, macos_ui) out there. Thats actually a very good development that highlights the power of the core flutter framework. Its not uncommon to include an template/starter system or just a list of options of ui libraries which could be downloaded via pub. Basically the same approach as with state management solutions (core widgets/classes + variety of community libraries) See the discussion ☂️ Reinforcement: Add more basic components to the core framework #97496

    *I don't see a "fragmented community" with this proposal just more choice and flexibility. If the material library should be the "de facto standard" for all platforms & use cases than its better to improve it and not bound it to the core framework. Also i'm not sure why cupertino is part of a cross-platform framework. Why should anyone use it on the web or desktop?!

  8. iapicca commented on Aug 24, 2022

    @iapicca

    copy paste from duplicate

    Use case

    • material 3 and material 2 coexistence through opt-in approach may be

      • confusing
      • have unwanted side effect (material2 regressions and or technical debt)

      having 2 separate packages would solve that

     return MaterialApp(
        theme: ThemeData(useMaterial3: true),
        // ...
      );
    • uses-material-design seems a "non standard" approach compared to other packages
      (even bundled ones like cupertino)
    flutter:
      uses-material-design: true
    • would make sense if material.io maintained it
      (possibly and eventually, but definitely not happening if it's just bundled in the sdk)

    • a strength of flutter is the ease of implementation of "branding", but sometimes if hindered by over reliance on material widgets and it's limited extensibility of it, un-bundling it would/may "force" the package to be more interoperable with flutter's core widgets and their extensions

    Proposal

    un-bundle (if that's even a word) material from flutter sdk an make it available as package

    Notes

    I have the feeling that this has been briefly discussed between the lines of some tangentially related issue
    (maybe this one?), but I couldn't find a "start to end" discussion about it

  9. Hixie commented on Aug 25, 2022

    @Hixie
    Contributor

    The problem with unbundling the material library is that flutter create has to create a template that uses a widget library of some sort, to help with the first hour experience (it's a lot more fun if you can just build an app without having to first figure out where to get buttons and so on). Most (all?) big platforms / UI frameworks / SDKs (e.g. the web, Windows, Android) do come with a baked-in set of widgets (actually Flutter is pretty unique in making its default set entirely optional and entirely defined in terms of lower-level primitives that you can just use directly; usually the default widgets are much more tightly integrated into the offering).

    We could depend on a split-out material instead of bundling it with the SDK, but that would not really make any difference; you'd still need to pin the exact version for quality-control purposes, just like we do with vector_math. The effect would just be to slow development and make it harder for people to test their changes.

    material depends on cupertino which is why we bundle cupertino as well.

    Responding to some comments above:

    From @nikitadol:

    • Long update cycle

    You can use the beta channel if you want faster updates. It uses the same release process as stable, but is updated monthly instead of every quarter. (You could also just use master, but that has had less testing.)

    • To get the new version - you need to update the version of Flutter

    As discussed above, the package and the SDK would be pinned in either case.

    • Random imports

    Not sure what this means.

    Only one widget set needs to ship with Flutter. We could talk about changing to another built-in set, e.g. using yaru as the out-of-the-box widget set, but I think in practice currently the material widgets are the most logical choice (since unlike most widget sets, they are designed to be cross-platform, like Flutter).

    @LasseRosenow:

    • If you don't use material or cupertino, but something like yaru or fluent, you are no longer annoyed by autocompletion that suggests you to use material or cupertino buttons. Sounds simple, but is a really bad user experience

    If autocomplete is annoying, please file a bug specifically on that. We should definitely not be surfacing things in autocomplete that you don't want.

    • The material / cupertino library can have easier breaking changes without needing tons of backwards compatibility by just increasing the major version number is something like material 3 or in the future perhaps material 4 is released. The developer does not need to update the package but can still upgrade flutter without needing to migrate the whole application to a major design system change

    Unfortunately since we need to pin the material and flutter versions, this advantage is not available to us.

    • Flutter becomes more like a better html / css kind of framework but without the html and css of course :D. Which is something I would like very much to happen. To have flutter just be the framework without making any assumptions as to what kind of design you want to implement. This would also make it more obvious to newcomers that flutter is not just to make material / cupertino apps.

    I agree that we should highlight other design languages. I'm not sure that this is more important than giving people a very fast out-of-box experience, though. Requiring that people think about what widget set they want when they're just experimenting with the framework is, IMHO, not conducive to a good experience.

    @iapicca:

    having 2 separate packages would solve that

    Having two packages would double the maintenance burden, which would just mean Material 2 no longer gets bug fixes.

    uses-material-design

    I believe we could get rid of this now, we'd just need to move to handling the Material icons font like we do the Cupertino icons font. Please feel free to file a bug on this if it's important to you.

    • would make sense if material.io maintained it
      (possibly and eventually, but definitely not happening if it's just bundled in the sdk)

    Actually the material.io team is already involved in package:material's creation. It would not substantially change who was developing it if it moved out of the SDK. (Actually if it moved out of the Flutter project's purview into a less open-source-friendly project, it would probably mean that fewer people could contribute, which seems net worse.)

    • a strength of flutter is the ease of implementation of "branding", but sometimes if hindered by over reliance on material widgets and it's limited extensibility of it, un-bundling it would/may "force" the package to be more interoperable with flutter's core widgets and their extensions

    In practice you can just not import package:material. We enforce a layering principle in the SDK to make sure nothing lower-level depends on the material library.

    Responding also to some comments in #110195 from @alestiago:

    As user of Flutter I don't want to be able to import material or cupertino. I want to enforce developers to use their own design system package. This is particularly common in big organisations where the design system is strict. Moving this out of "flutter" will avoid organisations developing their own scripts or workaround to prohibit importing material or cupertino into the main application.

    As far as I can tell there's no mechanism to prevent people from depending on a pub package any more than there is preventing them to depend on package:material. If you want to apply a style guide to disallow some package, it's relatively straight-forward to write a script to scan the code and flag uses of the banned package.

    As a Flutter developer I want to be able to update Flutter without updating material or cupertino. As Flutter has evolved, there are sometimes deprecations from material and in some applications, I don't want to update material (yet) but do want to update the framework itself.

    As discussed above, even if we moved it into a separate package, it would still need to be pinned so that we could guarantee that the template app worked. So this would not solve that problem.

    The framework can be kept small by moving material and cupertino as their own independent packages.

    We already do this by enforcing layering such that nothing outside of material depends on material (and nothing outside of cupertino and material depends on cupertino). It would not make a meaningful difference to the layering if it was in a separate package.

    FWIW, I think there is a world where eventually we have flutter create build from templates found in pub packages, and in that world we could consider having a material package that has a template and then the testing burden shifts sufficiently that we could think about not pinning the framework to the material library (or vice versa), by having flutter create automatically fetch the material package. It would need to be done very carefully. It would be interesting, though, since it would let us propose other such packages in the installation instructions (e.g. "flutter create -p macos" to get a macos-based template). (cc @christopherfujino)

  10. 145 remaining items

  11. redfieldchristabel commented on Mar 27, 2026

    @redfieldchristabel

    with this decoupling, should i expect that the feature like default back button on IOS on scaffold widget will now gone?

  12. Sshlale commented on Mar 27, 2026

    @Sshlale
  13. Piinks commented on Mar 27, 2026

    @Piinks
    Contributor

    with this decoupling, should i expect that the feature like default back button on IOS on scaffold widget will now gone?

    No, not at all. The libraries will work just as they do now. :)

  14. redfieldchristabel commented on Mar 28, 2026

    @redfieldchristabel

    No, not at all. The libraries will work just as they do now. :)

    how so, the scaffold widget are from widget whic is from flutter core lib rights. or scaffold are from material

  15. Piinks commented on Mar 30, 2026

    @Piinks
    Contributor

    The Scaffold class is defined in Material.

  16. knotbin commented on Apr 1, 2026

    @knotbin

    @Piinks is there any chance this tracking issue could be pinned on Flutter's issues page?

    The sheer amount and nesting of subissues makes it hard to find and I'd say it's a pretty important and notable development that many people are very interested in.

  17. flutter-triage-bot commented on Aug 4, 2026

    @flutter-triage-bot

    This issue is marked P1 but has had no recent status updates.

    The P1 label indicates high-priority issues that are at the top of the work list. This is the highest priority level a bug can have if it isn't affecting a top-tier customer or breaking the build. Bugs marked P1 are generally actively being worked on unless the assignee is dealing with a P0 bug (or another P1 bug). Issues at this level should be resolved in a matter of months and should have monthly updates on GitHub.

    Please consider where this bug really falls in our current priorities, and label it or assign it accordingly. This allows people to have a clearer picture of what work is actually planned. Thanks!

  18. Piinks commented on Aug 4, 2026

    @Piinks
    Contributor

    This issue is marked P1 but has had no recent status updates.

    But there have been so many updates. 😅 Just not in the main umbrella issue. Sit tight, bot. Big doings are afoot.

  19. added
    packageflutter/packages repository. See also p: labels.
    and removed
    frameworkflutter/packages/flutter repository. See also f: labels.
    on Aug 17, 2026
  20. tologonkudaiberdiuulu commented on Nov 9, 2026

    @tologonkudaiberdiuulu

    @Piinks any deadlines?

  21. zigapovhe commented on Nov 9, 2026

    @zigapovhe

    @Piinks any deadlines?

    @tologonkudaiberdiuulu Deadlines for? material_ui and cupertino_ui have been 1.0 on pub.dev since August, so you can use them now. This one's still open because it's an umbrella. The old SDK libraries only got deprecated in #192957 and won't actually be removed until sometime next year (#172942), plus there are a few leftover sub-issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

📜Issue was posted to Discord. Remove to have the issue reannounced. (For "design doc", "emergency")P1High-priority issues at the top of the work listc: proposalA detailed proposal for a change to Fluttercustomer: crowdAffects or could affect many people, though not necessarily a specific customer.design docTracks a design discussion documentp: cupertino_uicupertino_ui package in flutter/packagesp: material_uimaterial_ui package in flutter/packagespackageflutter/packages repository. See also p: labels.team-designOwned by Design Languages teamtriaged-designTriaged by Design Languages team

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions