For example, to import the Raleway and Roboto Mono font
files into a project, the folder structure might look like this:

Supported font formats

Flutter supports the following font formats:

.ttc

.ttf

.otf

Flutter does not support .woff and .woff2 fonts for all platforms.

2. Declare the font in the pubspec

Once you’ve identified a font, tell Flutter where to find it.
You can do this by including a font definition in the pubspec.yaml file.

flutter

fonts

family

Raleway

fonts

asset

fonts/Raleway-Regular.ttf

asset

fonts/Raleway-Italic.ttf

style

italic

family