I am using MikTex,pdfLaTex, WinXP_SP3. I want to create an index including foreign letters in correct alphabetical order. Using Xindy seems like a lot of hassle, so I would like to avoid it. How can I manually change the index file (.ind) after it is created, setting the entries in the correct alphabetical order?

I am going to answer my own question.

The preamble contains

\makeindex[columns=3,  intoc]

I have tried using makeidx, but it didn't work so I changed to imakeidx.

At the end of the file there is


With this setup, an index file is created and printed, but with all words starting with foreign characters at the front, which is incorrect.

Open the .ind file with notepad. Manually copy-paste the incorrectly placed entries into proper places, adding \indexspace entries as required. (This is easier done in wordpad, actually). Now make the following changes to the preamble:

%\makeindex[columns=3,  intoc]

The otherwise failed makeidx now prints the manually altered index file. Even the TOC entry of the index remains. Job done.

1 Answer 1



You may consider switching to XIndy, a much more powerful index generator, which supports sorting rules for many languages.

Helping Makeindex

The sorting of Makeindex can be influenced by specifying a sorting key. In the default setting, the character @ separates the sorting key from the word, which appears in the index, e.g.: \index{Strasse@Straße}, \index{Baecker@Bäcker}/\index{Backer@Bäcker} (depending on the sorting rule). Then Makeindex will sort the entries as Strasse and Baecker/Backer, but Straße and Bäcker will appear in the index.

Sorting of the .idx file

The previous method can also be used to write a script, which provides sort keys for the entries in the .idx file. However, new letter groups are not possible.

Sorting of the .ind file

Parsing the .ind file is more cumbersome. A style file could be written to add more logical markup to ease the parsing. After identifying the entries, the script could perform its own sorting, including adding new letter groups.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .