# Why app runs slow in local?

There are three main reasons why the app runs slow in your local system:

  1. getStaticProps has about 2-3 seconds of redundant overhead during development. Please refer this issue (opens new window) confirming the same. In case you replace getStaticProps with getServerSideProps you can resolve this issue but that won't be the case always, as you may not need server side props always.
  2. Some components of MUI are very complex and thus it takes some time to render those components on your local system.
  3. MUI components use sx prop and styled function which are internally styling the components using emotion (opens new window). When emotion is used, all the components take a little bit more time to render than normal.

You may refer this MUI discussion (opens new window) for detailed information on why MUI v5 is very slow.

When your app is running on your server or your site is live, you will not face this issue. It will run normally on the server.

Last Updated: 6/22/2023, 7:12:49 AM