How to Format Compact Numbers with the JavaScript Internationalization API
![](https://www.freecodecamp.org/news/content/images/size/w2000/2023/01/Format-Compact-Numbers.png)
Sometimes it can be difficult to fit large numbers into your site or app's layout, especially if you have to display several of them together. As a result, a lot of modern sites and apps use the same format to display large numbers in a compact way. For example,
Sometimes it can be difficult to fit large numbers into your site or app's
layout, especially if you have to display several of them together.
As a result, a lot of modern sites and apps use the same format to display large
numbers in a compact way. For example, displaying 123,000 as 123K.
freeCodeCamp's and Instagram profiles using compact number format.You
can do this by writing a custom format function, using a third-party library,
or, best of all, using a built-in JavaScript API.
![](https://lokalise.com/blog/wp-content/uploads/2021/03/Flutter.png)
Flutter localization and internationalization i18n with examples
![](https://media.dev.to/cdn-cgi/image/width=1080,height=1080,fit=cover,gravity=auto,format=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7x6km7fk0shl9fr780fu.png)
How to Format Numbers in JavaScript using Intl.NumberFormat - DEV Community
freeCodeCamp on LinkedIn: How to Format Compact Numbers with the
![](https://www.freecodecamp.org/news/content/images/size/w2000/2020/04/steven-hille-VP25o26erko-unsplash.jpg)
Internationalization
Florin Lungu on LinkedIn: How to Format Compact Numbers with the
![](https://i.ytimg.com/vi/RoKQXiPOzjU/hq720.jpg?sqp=-oaymwEhCK4FEIIDSFryq4qpAxMIARUAAAAAGAElAADIQj0AgKJD&rs=AOn4CLC2rNTYKLaO5ck9x6TBmQHdfPCBEQ)
React Ecommerce Website #16: Convert Numbers into Indian Currency with Intl Number Format API 🔥
![](https://www.freecodecamp.org/news/content/images/2022/05/IMG_20210522_135955.jpg)
Gerard Hynes
![](https://miro.medium.com/v2/resize:fit:1400/1*4kZ7lhqT_HWgl7hv4jhD8g.png)
How to get started with internationalization in JavaScript, by Alex Permiakov, We've moved to freeCodeCamp.org/news
Gerard Hynes on LinkedIn: How to Format Compact Numbers with the
![](https://res.cloudinary.com/practicaldev/image/fetch/s--FC9PDe9t--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zu50yukbnxvpytwjdc50.png)
Full JavaScript Internationalization CheatSheet! - DEV Community
freeCodeCamp on LinkedIn: How to Format Compact Numbers with the
![](https://support.socrata.com/hc/article_attachments/115009358847/Screen_Shot_2017-04-04_at_1_14_33_PM.png)
European Number Formatting in the API – Data & Insights Client Center
freeCodeCamp di LinkedIn: How to Format Compact Numbers with the
GitHub - thiagodp/intl-number-helper: 💰 Configure EcmaScript's Intl.NumberFormat with a string pattern