Notes Compacting

I’ve been asked a number of times by people who use Notes about databases with not too many documents in them yet lots of space consumed.  This is particularly important when trying to free up space with low quotas imposed.  The problem comes down to the fact that with local replicas the indexes created to allow notes to open views and folders quickly may not get discarded if they are unused.  Hence if you have lots of folders your mail file size may grow to a point where documents only form a small portion of the overall size.  I’ve simplified things here…


In most cases the compact performed from within the notes client only gets rid of the space freed up from deleting documents.  So  if you find you are having problems getting below a quota try this:

  1. Open a command prompt (one way to do this is to click start – run – enter “cmd”)
  2. You’ll need to know the folder your lotus notes executables sit in.
  3. Then change directory to that folder.  That may be cd “c:program fileslotusnotes” but in later versions of notes that has changed.
  4. Next you’ll need to know where your data files are.  In my case it is c:program fileslotusnotesdata
  5. Now the magic command to get rid of indexes and the space left from deleting documents

    ncompact.exe “TheFullPathToYourMailFile” –D

    In my case it is ncompact.exe “c:program fileslotusnotesdatamailsdownes.nsf” -D

I’m sure someone who reads this will have a wonderful script which runs from a button 🙂  If you have lets see it 🙂

Technorati Tags: ,


  1. Stu, an account that I support has such a button built into the mail template. I’ll give you the details if you’re interested, or you can help yourself. 🙂


  2. Wow! A 47% decrease in my current mail file and an average of 20% decrease for each of my archive files. Thanks for the tip!


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s