Library / SDK
FortAwesome/react-fontawesome avatar
FortAwesome/react-fontawesome

react-fontawesome: the React component for Font Awesome SVG icons

Official React Component for Font Awesome Icons

3,738 stars271 forksTypeScriptMIT

At a glance

What is it?
A small TypeScript wrapper that turns a Font Awesome icon name into an inline SVG React element, rewritten for version 3 and published with type definitions, a named export for custom prefixes, and a version support matrix that tells you which React it expects.
Who is it for?
react-fontawesome earns its place by being the thinnest thing that can still be official: it renders SVG, it ships TypeScript types, and it declines to bundle an icon set of its own, so you control which icons reach your bundle. Version 3.5.0 came out on 2026-07-20 and the last push was on 2026-09-13, on a repository that is not archived.
Can I use it commercially?
Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 3 days ago.
What is it written in?
Mainly TypeScript, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on October 7, 2026, and from our analysis. They are not legal advice.

Editorial analysis

The repository is a component, not an icon set

This is the first thing to get straight, because it is the most common misunderstanding. The repository holds no icons. It holds the React binding that turns an icon name into an inline SVG element, and the README describes it as a Font Awesome React component using SVG with JS. The icon data itself comes from a separate Font Awesome core package that you install and configure yourself.

The practical effect is on your bundle size. With the webfont approach every icon is a glyph in one font file. With this component each icon is an SVG node in your JavaScript, so what you pay for is the icons you actually import rather than the whole set. That is the trade the project is built around, and it is also the trade that pushes bundle analysis onto you: an icon imported carelessly at the top of a component tree lands in the chunk for every route that imports it.

The repository topics are `fontawesome`, `frontend`, `javascript` and `react`, and the package description reads Official React component for Font Awesome. There is no server, no build pipeline to run, no configuration file to write. You add a dependency and import a component.

What version 3 changed: plain JavaScript became TypeScript

The README is direct about the 3.0.0 rewrite, calling it a major update in which the library moved from plain JS to TypeScript, with performance work on the `FontAwesomeIcon` component alongside it. The claim it makes is modest and worth repeating accurately: no breaking changes beyond the ones listed in the compatibility table.

That table is the single most useful thing in the README, because it maps your React version to the right line of this package, the Font Awesome core versions, and the Node versions. React 18 or newer pairs with react-fontawesome 3.x, Font Awesome core 6.x or 7.x, and Node 20, 22 or 24. React 16.3 and above drops to the 0.2.x line, which still accepts core 5.x. Anything below React 16.3 is on 0.1.x with Node 14 or 16.

That last column matters more than it looks. `react-fontawesome` 3.x no longer supports Font Awesome 5, which the README says is marked End-of-Life following the release of Font Awesome v7, and it also dropped End-of-Life React and Node versions plus IE11. If you are on an older React, the answer is not to force a 3.x install but to accept the 0.2.x line and its older core support.

Dual package output and the CustomPrefixProvider subpath

The published package is an ES module with CommonJS kept alongside it, and `package.json` exports a second entry point beyond the root. That structure tells you what the maintainers expect: bundler consumers get the ESM build, and anyone who needs to control how icon names map to prefixes imports a dedicated provider rather than configuring a global.

json
"main": "./dist/index.cjs",
"module": "./dist/index.js",
"types": "./dist/index.d.ts"

The named export map entry for `./CustomPrefixProvider` has its own type, ESM and CJS files, which is a tidy way to ship a secondary API without widening the root surface. For a library this small, dual publishing and per-entry types are the details that decide whether your build tool complains or not, and getting them right is most of the maintenance burden a component like this carries.

TypeScript definitions come from the same build. The repository config makes that explicit: `tsconfig.json`, `typedoc.config.mjs` for generating API documentation, `tsup.config.ts` for the bundle, and a `docs/` directory. The published API reference is hosted separately at the project's GitHub Pages site rather than in the repository.

Release notes that describe icon features, not component features

The release history is short and unusually informative for a wrapper library, because the changes come from the icon library underneath it. Version 3.5.0 on 2026-07-20 is a single feature: new canvas options, which is a Font Awesome capability rather than anything in the React component. Version 3.4.0 on 2026-07-08 added support for the new animations introduced in Font Awesome 7.3.0.

Version 3.3.1 in April 2026 is the most revealing of the three, because it is nothing but dependency bumps, and the note explains why: closing off CVEs, with the caveat that the library itself is not really affected. It also pins the Node version the project develops against and bumps dev dependencies.

Read together, these notes tell you the maintenance model. This package follows Font Awesome core, so an upgrade of core can require an upgrade here, and the interesting question before bumping is whether the release you want mentions the icon feature you need. A reader looking for a specific animation or canvas option should check the release notes for the version that added it rather than assuming the latest tag has everything.

Where the README hands off to fontawesome.com

The README links two things and explains neither, which tells you where the boundary sits. One is the Use With React page in the official Font Awesome documentation at docs.fontawesome.com. The other is the API reference, hosted on the project's own GitHub Pages site at fortawesome.github.io/react-fontawesome.

So the repository answers what version pairs with what, who maintains it, and how it is released, and it does not answer how to configure the component, which props it takes, or how to set up the core package it depends on. That is a defensible split for an official binding: the setup instructions belong with the icon library and will read the same whether you are using React, Vue or the plain JavaScript build.

The repository does carry a `CONTRIBUTING.md`, a `CODE_OF_CONDUCT.md`, a `DEVELOPMENT.md` and a long contributor table, plus `.husky/` and `commitlint.config.ts` for enforcing conventional commits. The release process is documented in `DEVELOPMENT.md`, and the README notes that releasing is restricted to project owners. Tests run through `jest.config.ts` with a `test-setup/` directory. All of that is normal hygiene for a small library and none of it changes how you use it.

The comparison worth making is with an unstyled icon component

The honest alternative is not another icon set, it is the pattern of writing your own icon component. A thin wrapper around a set of inline SVGs is a weekend of work, and if your icons are internal to your product there is a real argument for owning that code rather than taking a dependency on someone else's release cadence.

What the official component buys you is the part that is tedious to keep correct: TypeScript types that match the Font Awesome icon names, dual ESM and CommonJS output, a subpath export for prefix handling, and release notes that tell you when a new core icon feature is supported. It also costs you a version matrix to respect, since the 3.x line and the 0.2.x line support different combinations of React, Node and Font Awesome core.

The other comparison is against the font itself. If you do not need per-icon control, a webfont approach avoids per-icon JavaScript entirely, and if you need neither the types nor the custom prefix handling, paying for this wrapper buys little. The deciding question is whether your build gives you control over what ends up in each chunk.

Editorial conclusion

react-fontawesome earns its place by being the thinnest thing that can still be official: it renders SVG, it ships TypeScript types, and it declines to bundle an icon set of its own, so you control which icons reach your bundle. Version 3.5.0 came out on 2026-07-20 and the last push was on 2026-09-13, on a repository that is not archived. It is the wrong choice if you need Font Awesome 5 or React below 16.3, because both were dropped in the 3.x line. Install `@fortawesome/react-fontawesome` alongside a Font Awesome core package, read the compatibility table in the README before you pick a version, then confirm the animation support for your Font Awesome 7 icons in the 3.4.0 release notes.

Frequently asked questions

How do you use Font Awesome icons in React?

Install `@fortawesome/react-fontawesome` alongside a Font Awesome core package, then import the `FontAwesomeIcon` component and pass it an icon you have imported from core. The README points to the Use With React page on docs.fontawesome.com for the setup steps, and describes this package as a React component using SVG with JS rather than a webfont.

Is Font Awesome still in active use?

Yes. The README states that with the release of Font Awesome v7, v5 was marked End-of-Life, while v6 and v7 continue to be supported. This repository is not archived, the last push was on 2026-09-13, and version 3.5.0 was released on 2026-07-20.

Which React version does react-fontawesome 3.x need?

React 18.0.0 or newer, paired with Font Awesome core 6.x or 7.x and Node 20, 22 or 24. The compatibility table in the README maps React 16.3 and above to the 0.2.x line, which also accepts core 5.x, and anything below 16.3 to 0.1.x on Node 14 or 16.

Does react-fontawesome bundle the icons itself?

No. The repository holds the React binding that renders an icon as an inline SVG, not the icon data. You install a Font Awesome core package separately and import the icons you want, which is what lets you keep only the icons you use out of your bundle.

What license is react-fontawesome released under?

MIT, according to the repository metadata and the `LICENSE.txt` file in the tree. That is the most permissive of the common open source licences and imposes no reciprocity condition on code that depends on it.

Official sources

  1. FortAwesome/react-fontawesome on GitHub
  2. License: MIT
  3. Project website
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/fortawesome-react-fontawesome.svg)](https://hysenlabs.com/projects/fortawesome-react-fontawesome)