File extensions

From Lazarus wiki
Revision as of 17:26, 9 November 2020 by Arent (talk | contribs) (Project files)

File extensions

Some file extensions


Project files

extension description
.lpi Lazarus Project Information file (stored in XML; contains project-specific settings)
.lpr Lazarus Program file; contains Pascal source of main program
.lfm Lazarus Form file; contains configuration information for all objects on a form (stored in a Lazarus-specific format; the actions are described by Pascal source code in a corresponding .pas file)
.pas Unit with Pascal code (typically for a form stored in a corresponding .lfm file)
.pp Pascal code
.lrs Lazarus Resource file (this is a generated file; not to be confused with a Windows resource file).
.ppu Compiled unit, symbols part.
.o (1) Compiled unit, code part.
(2) Compiled code from other compilers (e.g. gcc)
.or object resource, automatically generated from {$R} directive.
.a (1) Compiled unit, code part for smartlinking (on some platforms)
(2) Compiled code from other compilers (e.g. gcc) linked into a static library
.lpk Lazarus package information file. (stored in XML; contains package-specific settings)
.inc Include file
.lps Lazarus Project Session file. See Project Options Save session information in
.lrt Lazarus Resourcestring table created when saving a .lfm file and i18n is enabled. It contains the TTranslateString properties of the .lfm.
.rst Resourcestring table created by the compiler for every unit with a resourcestring section.
.rsj Resourcestring table in JSON format created by FPC 2.7.1 for units with resourcestring section.
.compiled compilation session for a project
.ico program icon
.gitignore list of files/directories to be ignored when using git
.rc resource file
.res compiled resource file

Subversion or Git

These files would normally be stored in a repository as an adequate description of a project:


These files might contain manually-generated or imported information, or might be regenerated by the IDE or build process. In general, if they have the same basename as the project or a form or unit they're IDE-generated, but in all cases should be reviewed individually:


These files are regenerated by the IDE or by a build so do not need to be stored:


There is an example .gitignore file at [1].


Project files

   Delphi form module
   Delphi project options file
   Desktop configuration

Converting Delphi projects

Lazarus can convert at least some Delphi project files into its own format.



   Text file
   Gettext Portable Object
   Config file
   Compiled Help File - contains html. See also package chm
   Comma Separated Values text file format 
   Directly executable program
   Help file
   Initialization file
   OpenDocument text document
   Portable Document Format
   Rich Text Format text file


   Portable network graphic
   portable pixmap 
   portable graymap 
   portable bitmap 




   Hypertext Markup Language
   Cascading style sheet


   tape archive


   Database file
   Multiple index file


*.ods Calc spreadsheet File Format
   Microsoft Excel File Format
   Microsoft Office Open XML Excel File Format 

Operating system

Linux and Unix

   Shared object library
   Shell script
   Debian Package
   Red Hat Package Manager 


   Application bundle
   Disk Image File 
   Dynamic shared library


   Batch file. It's a text file that contains a sequence of commands for a computer operating system.
  dynamic-link library
   Directly executable program

See also

Alphabetical list of file extensions