Managing Your Money with GnuCash

by Robert Merkel

A refrain many Linux users and advocates hear again and again is “The only reason I keep Windows around is for Quicken.” Since 1997, the GnuCash Project (formerly known as xacc) has been working to provide an accounting solution for Linux. GnuCash 1.4, the current stable release, provides a simple, easy-to-use but powerful home accounting system. Development continues at a rapid rate, both through volunteers and employees of Gnumatic (, a company formed to support the continued development, marketing and productization of GnuCash and related projects.

Obtaining and Installing GnuCash

GnuCash is GPL software, so you can download the source code, as well as RPMs, from the GnuCash web site ( Several distributions, including Mandrake, SuSE, Debian and Red Hat, also include GnuCash as part of their systems. While GnuCash requires the GNOME libraries, it will run quite happily with any window manager, including KDE. The current stable version is 1.4.9, but that may have changed by the time you read this. Versions 1.5.x are the next development series. These are intended for those who wish to get involved with where GnuCash is going, rather than its use in production environments.

Building GnuCash can be a little problematic for some people as it requires the installation of a couple of uncommon build tools. In addition to a working GNOME development environment, you need Perl, guile, SWIG (available from and g-wrap, another tool now maintained by Gnumatic and available from the Gnumatic web site. The dependency on SWIG is likely to go away sometime in the next development series (1.5.x). GnuCash uses the standard GNU build environment, so compiling is just a matter of typing ./configure; make; make install.

While GnuCash's primary development environment is Linux on x86, it has been successfully compiled and run under virtually all the architectures Linux supports, as well as FreeBSD/x86 and Solaris/x86. It should also run on just about any platform to which GNOME has been ported.

Remedial Accounting 101

While many other low-end accounting programs use a “cashbook” single-entry approach to accounting, GnuCash has always used a double-entry accounting system. While slightly more complex, double-entry accounting is a far more accurate accounting technique. You'll find that double-entry is a powerful way of organizing your finances. If you are already familiar with double-entry accounting, you probably can't imagine working any other way. While it's technically possible to use GnuCash for single-entry accounting, you'd be crazy not to take advantage of GnuCash's full abilities.

So, how does double-entry accounting work in GnuCash? Every time you spend, receive or transfer money is a “transaction”. When you write a check to pay your phone bill, that's a transaction. When your paycheck goes into your account—another transaction. When you go to the ATM to get some cash for a night out, that's a transaction. When you buy a burger with that guessed it, it's a transaction (whether it's practical to account for personal burger purchases is another question). In each case, money is transferred from one place to another, and the amount taken from one place must exactly equal the amount put somewhere else. Money never appears or disappears from thin air.

Similarly, in GnuCash every transaction involves money transferred from one account to another. “Huh? Two accounts?” I hear you saying. “Okay, for a bill payment one of those accounts might be a checking account, but what's the other?” Good question. The answer is that “accounts” can be much more than checking or credit card accounts. For instance, you can create an “expense account” for “Phone Bills”. Therefore, paying a phone bill would involve two entries, one in your checking account, and one in the “Phone Bill” expense account. These amounts must exactly match, something that GnuCash immediately checks. At this point, you might think that making two separate entries is a pain. GnuCash, however, lets you make both entries at the same time. More information on double-entry accounting is available in the GnuCash documentation (on-line at

So, let's create some accounts in GnuCash and record a $100 phone bill payment. Start up GnuCash. If you installed from a binary package there's probably a menu entry somewhere, but if that's not set up just type gnucash at a command-line prompt. You'll see the main window. First, we'll need to create some accounts. One way to do so is to click on the “New” button in the toolbar, which brings up a dialog box for creating accounts.

We'll create an account to represent our checking account. In the dialog box, enter the account's details. Most of the fields are self-explanatory, but there are a few that could use some explanation. The “Account Code” is used to determine the order of display in the main window and has no other effect on the account. If you don't care what order they are displayed in, you can safely leave it blank. “Account Type” is where things start to get interesting. GnuCash has 11 different account types. Our checking account is a “bank” account. Finally, you must select a “parent account”. What's that? All will be revealed later, but for now just select “new top level one too”.

Next, we'll create the “Phone Bill” expense account. Click on the “new” button, and repeat the process. The currency for the new account must be the same as for the bank account (transferring between different currencies is performed using special “currency” accounts). Make sure you set the type of the account as “expense”. You should also select “new top level account” for this account.

If you're going to pay a phone bill, you've already got some money in your bank account. According to the rules of double-entry accounting, that money had to come from somewhere, right? Therefore, we create a special “equity” account. Repeat the process you used to create the previous accounts, but call this one “My Equity” and make it of type “equity”.

Now, enter the initial bank account balance. Open the register for the newly created bank account by double-clicking on the entry in the main window. The register shows all the transactions and a running balance for the current account. At the bottom of each register there is always a blank line to enter new transactions. The column headings display transaction fields: date, number, description, transfer (which account the transaction involves transfer from/to), deposit, withdrawal and balance.

Let's say that your current balance is $1,000.00, and we'd like to record that. The date is already set to today's date, so there's no need to modify that field. Use the tab key or the mouse to move to the next field, the description field, where we type Opening Balance. Next, we select the account where we're transferring money from—the special “My Equity” account. Enter the amount ($1,000.00) into the deposit field, and press enter to record the transaction. A new blank transaction will be created, and the balance will change to record the current account balance.

Finally, enter the phone bill. Enter the appropriate information in each field: check number, description of the transaction and the other account involved in the transaction. The transaction is recorded, the new balance for the account is calculated and a new blank transaction is recorded.

Creating an Account Hierarchy

The simple example has covered most of what's needed to use GnuCash to track your expenses. You can go ahead and create expense, income, bank and cash accounts to meet your needs. However, if you conduct a lot of different types of transactions and end up with a bunch of accounts, there are going to be a lot of accounts for fairly similar types of transactions. Wouldn't it be convenient if you could somehow group these accounts? GnuCash lets you do just that. In fact, GnuCash is designed around the concept of a chart of accounts or account hierarchy, in which accounts are placed in a tree structure.

For instance, wouldn't it make sense to group together all the different sorts of utility bills, such as electricity, water and phone? GnuCash can do that. First, create a general Utilities expense account, just like you created the Phone Bill expense account. Next, create an Electricity expense account, but this time, in the “parent account” field of the dialog box, select Utilities rather than “New top level account”. Repeat the process to create a Water expense account under the Utilities account.

And now let's just add an account for phone bills...uh, wait, we already have one of those. What do we do now? Do we delete that account, make a new one and re-enter all those transactions? No, we can move the “Phone Bill” account to make it a child of the Utilities account. In the main window, click on the Phone Bill account, then either click on the “edit” toolbar button or right click on the highlighted main window entry, and select “edit account”. Either way, you bring up the “edit account” dialog box where you can change any properties of the selected account. Change the parent account to Utilities, and click “OK”. That's it!

Importing from Quicken

So far, we've assumed that we've never used accounting software before. For many people that's not the case, and Quicken's QIF format is probably the most common way that people export data from their systems. Microsoft Money can also export QIF. Check the documentation of your particular system to find out whether your package can export QIF. Unfortunately, Quicken's QIF file has some rather interesting “features” and design decisions (including recording dates differently depending on your location), so importing your data into GnuCash requires a little manual intervention along the way.

GnuCash's on-line help system (accessible from the help menu) covers the importation process in detail. In fact, the on-line help system is a comprehensive guide to all of GnuCash's features and gives quite a lot of accounting background, not just the details of GnuCash's operation. To use the on-line help just select “help” from the main window. Many dialog boxes also have a help button available.

In any case, let's assume you have exported a QIF file with all your accounts, that you want to import to GnuCash. From the GnuCash main window, go to the File menu and select “import QIF”, which brings up the import dialog box. First, select the QIF file you wish to import, and select the default currency for this QIF file. Next, give a name to the default account, and specify the currency in which this QIF records transactions. Then, click on “load file”. If you have multiple QIF files you wish to import at once, repeat the process.

The QIF importer then examines the QIF files, creates an account structure that matches the original QIF categories and accounts with GnuCash accounts, and checks for any duplicate transactions. This is quite a complex process so don't be concerned if it takes a while and GnuCash doesn't respond to user input. It also guesses the appropriate account type for each category. While the QIF importer usually guesses correctly, it's wise to check. You can also add descriptions and change the parent of accounts. If you want to do this later, you can do it from the main window. Anyway, when you've checked everything just click OK, and importation will be complete!

You can also import QIF into existing GnuCash files. Use the same process as above, but this time you'll probably have to use the “accounts” and “categories” tabs of the QIF importer to tell GnuCash in which of your existing accounts to place various transaction categories. These days, many banks are able to provide QIF files representing all transactions in an account over a period of time. You can use the QIF importer to import those transactions automatically into the system.


GnuCash can also assist you in reconciling your records against your bank statement. When you receive a bank statement, just choose that account and then right click and select “reconcile”. Tell GnuCash the ending balance on the statement, and the reconcile window is displayed (see Figure 1).

Figure 1. The Reconcile Window automates the process of reconciling your records against your bank's.

You should then go through your bank statement, and check the uncleared transactions against the transactions on the statement. If they match (and the amounts are correct) click that transaction to clear it. When the process is complete, the difference field at the bottom of the window should be $0.00. If it isn't, there's a discrepancy between your record and the bank's. Either you've missed a transaction (have you checked the bank's fees and government charges?), an amount is wrong or the bank has made an error (possible, but unlikely).

Stocks and Other Investments

GnuCash has extensive facilities for tracking investments in stocks and mutual funds. When you purchase a new stock or open a mutual fund, you should open a stock or a mutual fund account, just like a bank account. When you open the account, make sure you enter the correct ticker symbol in the Security field, and select a source quote.

While automated, updating prices is done from outside GnuCash with the gnc-prices Perl script. When the script is run, all the available prices are updated.

Recording stock purchases and sales is performed using the stock account register, which works just like the other registers except you should enter a price and a quantity of shares/units instead of just one value.

What? You want to analyze the performance of your shares? For that, you need...


GnuCash has some very useful reporting capabilities that you can view directly or export as HTML for permanent storage or printing. Current CVS has direct printing support through gnome-print, but this has not made it into release versions yet.

One of the most basic reports is the “balance sheet”. This report summarizes your assets and liabilities, thus showing your net worth. To display the report, simply select “Balance Sheet” from the report menu. A report window will open and display the report. By default, it displays the balance sheet as of this moment, but that's adjustable. Click on the “parameters” button, which brings up a dialog box from which you can change options for the report.

An overview of your stock portfolio is also available, as well as the account balance tracker, a very useful report for tracking the growth of a specific stock or mutual fund. This report also supports graphing if you have gnuplot installed. Finally, the transaction report lists all transactions meeting a set of criteria. This flexible report is often useful for extracting specific information not available in other reports (see Figure 2).

Figure 2. The Transaction report can be used to display and subtotal transactions in a variety of ways.

If the current reports do not meet your needs, you can write your own. The “hello world” report is the GnuCash authors' test bed and serves as a basis for those who wish to write a custom report.

Future Plans

While GnuCash is stable and useful right now, Gnumatic and the rest of the GnuCash community have big goals for the future. Already, the development CVS tree has several new features, and many more are planned.

The coming 2.0 release is under heavy development, and plans are afoot for a Q1 2001 release. Some of the features that will be part of 2.0 include:

  • A new, XML-based file format that will be more compact and versatile.

  • Printable reports (courtesy of gnome-print and the gtkhtml widget).

  • Better graph capabilities through GUPPI (which will hopefully be widely adopted as the standard Gnome graph infrastructure). Development of GUPPI has been supported by Gnumatic.

  • Much improved report flexibility and customizability.

  • Much improved stock market reporting.

Further improvements to GnuCash's personal accounting abilities are planned in the long term. Some of these include:

  • Improvements to on-line stock quote gathering and currency quotes.

  • Interfacing to on-line banking, including OFX and other standards.

  • Interfacing to Palm PDAs.

  • Full documentation of the guile API to make writing extensions easy.

While GnuCash's current emphasis is on personal accounting, the large number of requests for business accounting functionality we receive on the mailing list are not being ignored. GnuCash will form the basis of a full-featured, multiuser accounting package with a database engine; CORBA bindings; and support for payroll, inventory, invoicing and the other features that larger businesses require from accounting systems. Gnumatic will be in the forefront of this, offering its services to customize and support GnuCash for specific customers, industries and countries.

Robert Merkel started hacking on GnuCash because he was sick of supporting his father's Windows box. Robert is now a full time GnuCash developer and an employee of Gnumatic, Inc.
Load Disqus comments