Invoice Ninja is a free, open source finance & accounting project written in PHP and released under a custom open-source licence. It has 10,086 GitHub stars, 2,707 forks and 945 open issues, and was last pushed 16 hours ago. On this registry it ranks #7 of 34 tracked projects in Finance & Accounting, and is listed as an open source replacement for 3 paid products, with 5 head-to-head comparisons available. It gained 12 stars over the last 6 tracked days.

What is Invoice Ninja?

What it is

Invoice Ninja is a source-available invoice, quote, project, and time-tracking application built with Laravel and PHP. It lives in the Laravel ecosystem and is positioned as an open alternative to QuickBooks, Xero, and FreshBooks. The project provides a web application, API, desktop clients, and mobile clients for businesses that need to bill clients and manage payment-related work.

The concrete problem it solves is the need to create and send invoices, track expenses, manage quotes and projects, record time, and accept payments without depending entirely on proprietary accounting platforms. It offers a hosted software-as-a-service option for users who want no server management, and a self-hosted option for users who want full control over their data and infrastructure. The self-hosted version includes all Pro and Enterprise features from the hosted application, and a $40 per year white-label license can remove Invoice Ninja branding from client-facing parts.

Key capabilities

  • It creates and manages invoices, quotes, expenses, projects, and time-tracking records.
  • It supports electronic invoicing workflows, as indicated by the einvoicing topic.
  • It accepts payments through recommended payment providers such as Stripe.
  • It sends client-facing communications through recommended providers such as Postmark.
  • It includes kanban features for organizing work, as indicated by the kanban topic.
  • It offers Flutter-based mobile apps for iPhone, Android, and F-Droid, plus desktop apps for macOS, Windows, Linux Snap, and Linux Flatpak.
  • It exposes an API and a Go SDK for programmatic integration.

Who uses it and how

  • Businesses can use the hosted option to send invoices and accept payments without managing hosting or server infrastructure.
  • Self-hosters can run the application on a server or virtual machine, Docker, Cloudron, Softaculous, Elestio, or YunoHost while retaining control over their environment.
  • Users can manage billing work from desktop applications on macOS, Windows, Linux Snap, or Linux Flatpak.
  • Users can create and track invoices, quotes, expenses, projects, and time entries from mobile applications on iPhone, Android, or F-Droid.
  • Developers can connect external systems through the API documentation and the Go SDK.

Getting started

Typical methods include the hosted service, self-hosted installation on a server or virtual machine, Docker deployment with the invoiceninja/invoiceninja image, and installation options through Cloudron, Softaculous, Elestio, or YunoHost. The README also describes an advanced self-hosted setup using git clone, composer install, database migrations, sample data seeding, and php artisan serve.

When to use it — and when not to

Invoice Ninja fits users who want an open alternative to QuickBooks, Xero, or FreshBooks and are willing to operate hosting, database, payment, and email configuration themselves. Self-hosters must manage server infrastructure, configure recommended services such as Stripe and Postmark, and preserve the application key, because losing it prevents the application from running. The source-available status, the $40 per year white-label license, and the operational requirements may not suit users who want a standard open-source license or who do not want to manage infrastructure.

project readme (upstream, from github) — read inline

Sublime's custom image

v5-develop phpunit Codacy Badge CLA assistant

Invoice Ninja 5

Invoice Ninja Version 5 is here! We've taken the best parts of version 4 and added the most requested features to create an invoicing application like no other. Check the Invoice Ninja YouTube Channel to get up to speed, or try the Demo now.

Choose your setup

  • Hosted: Our hosted version is a Software as a Service (SaaS) solution. You're up and running in under 5 minutes, with no need to worry about hosting or server infrastructure.
  • Self-Hosted: For those who prefer to manage their own hosting and server infrastructure. This version gives you full control and flexibility.

All Pro and Enterprise features from the hosted app are included in the source-available code. We offer a $40 per year white-label license to remove the Invoice Ninja branding from client-facing parts of the app.

Get social with us
Documentation

Installation Options and Clients

Mobile Apps

Desktop Apps

Self-Hosted Server Installation

Note: The self-hosted options do support the desktop and mobile apps.

Recommended Providers

SDKs available for easier API consumption

[Advanced] Quick Hosting Setup

In addition to the official Invoice Ninja - Self-Hosted Installation Guide we have a few commands for you.

git clone --depth 1 -b v5.11.53 https://github.com/invoiceninja/invoiceninja.git
cp .env.example .env
composer i -o --no-dev

Note replace v5.11.53 with the latest tag version, you will also want to ensure that when performing updates, you use the latest tag version rather than a particular branch, ie v5-develop. This will ensure that you are not pulling in work in progress code.

Please Note: Your APP_KEY in the .env file is used to encrypt data, if you lose this you will not be able to run the application.

Run if you want to load sample data, remember to configure .env

php artisan migrate:fresh --seed && php artisan db:seed && php artisan ninja:create-test-data

To run the web server

php artisan serve 

Navigate to (replace localhost with the appropriate domain)

http://localhost:8000/setup - To setup your configuration if you did not load sample data.
http://localhost:8000/ - For Administrator Logon

user: [email protected]
pass: password

http://localhost:8000/client/login - For Client Portal

user: [email protected]
pass: password

Developers Guide

In addition to the official Invoice Ninja - Developer Guide we've got your back with some insights.

App Design

The API and client portal have been developed using Laravel if you wish to contribute to this project familiarity with Laravel is essential.

When inspecting functionality of the API, the best place to start would be in the routes/api.php file which describes all of the availabe API endpoints. The controller methods then describe all the entry points into each domain of the application, ie InvoiceController / QuoteController

The average API request follows this path into the application.

  • Middleware processes the request initially inspecting the domain being requested + provides the authentication layer.
  • The request then passes into a Form Request (Type hinted in the controller methods) which is used to provide authorization and also validation of the request. If successful, the request is then passed into the controller method where it is digested, here is an example:
public function store(StoreInvoiceRequest $request)
{

    $invoice = $this->invoice_repo->save($request->all(), InvoiceFactory::create(auth()->user()->company()->id, auth()->user()->id));

    $invoice = $invoice->service()
                        ->fillDefaults()
                        ->triggeredActions($request)
                        ->adjustInventory()
                        ->save();

    event(new InvoiceWasCreated($invoice, $invoice->company, Ninja::eventVars(auth()->user() ? auth()->user()->id : null)));

    return $this->itemResponse($invoice);

}

Here for example we are storing a new invoice, we pass the validated request along with a factory into the invoice repository where it is processed and saved.

The returned invoice then passes through its service class (app/Services/Invoice) where various actions are performed.

A event is then fired which notifies listeners in the application (app/Providers/EventServiceProvider) which perform non blocking sub tasks

Finally the invoice is transformed (app/Transformers/) and returned as a response via Fractal.

Developer environment

Using the Quick Hosting Setup describe above you can quickly get started building out your development environment. Instead of using

composer i -o --no-dev

use

composer i -o

This provides the developer tools including phpunit which allows the test suite to be run.

If you are considering contributing back to the main repository, please add in any tests for new functionality / modifications. This will greatly increase the chances of your PR being accepted

Also, if you plan any additions for the main repository, you may want to discuss this with us first on Slack where we can assist with any technical information and provide advice.

Credits

Want More?

Checkout our other projects here!

Event Schedule

Security

If you find a security issue with this application, please send an email to [email protected]. Please follow responsible disclosure procedures if you detect an issue. For further information on responsible disclosure please read here.

License

Invoice Ninja is released under the Elastic License.
See LICENSE for details.

Frequently asked questions

Is Invoice Ninja free to use?

Invoice Ninja is open source. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does Invoice Ninja do?

Send invoices, accept payments, manage your business—all free

What is Invoice Ninja written in?

Invoice Ninja is primarily written in PHP. Its source is publicly available at https://github.com/invoiceninja/invoiceninja, and it has 10,086 GitHub stars.

What is a good open source alternative to FreshBooks?

Invoice Ninja is one of the open source options listed as an alternative to FreshBooks, QuickBooks, Xero. Compare licences, stars and activity side by side on the Invoice Ninja profile.