TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to write in urdu with nastaleeq font. I have done quite a few things but i dont know how to write it. Plus i dont know how to use xetex. So can anyone give me a simple example writing urdu in the desired font and how to run it on texmaker.

share|improve this question
Try patriot.net/~abdali/urdumac.html#TypesettingWithTeX, should mostly apply to non-Mac users as well. – Khaled Hosny Sep 27 '13 at 7:37
Could it be persian nastaleeq? I know udro and persian are fairly similar but I'm not sure about different characters... – Pouya Sep 27 '13 at 14:35
i couldnt get anything that i wanted from the above link. If you know how to run xetex in texmaker(which changes are required in the settings) then do tell me – Shaheryar Sep 29 '13 at 9:10

Here is a typesetting of poem using IranNastaliq font and XePersian package. XePersian is included in texlive and in case you are missing it, you can get it from CTAN. One problem here is the font. IranNastaliq is designed for persian/farsi alphabet and despite of similarities between persian and urdu, it misses some of letters of urdu such as

enter image description here

This being said, I think you can find an urdu nastaliq font, just add it to you tex file and you will be good to go. I don't see any major difference between typesetting persian and urdu. Here is a sample tex file containing a poem from Saadi with nastaliq font.


\title{سر عشق}


\myverse{هزار جهد بکردم که سر عشق بپوشم}
{نبود بر سر آتش میسرم که نجوشم}

\myverse{به هوش بودم از اول که دل به کس نسپارم}
{شمایل تو بدیدم نه عقل ماند و نه هوشم}

\myverse{به راه بادیه رفتن به از نشستن باطل}
{که گر مراد نیابم به قدر وسع بکوشم}


which gives you this:

enter image description here

Please note that this is just a MWE and needs certain modification to be suitable for you purpose.

You can compile this from command line using:

xelatex your_poem.tex

To you use it with TexMaker, refer to this question.

enter image description here

Above tex sample is borrowed from XePersian Forum and it's respected creator.

share|improve this answer
i tired the things that were given in the link provided by you but it keeps on running like forever ; The texmaker i have installed on my system has a option in Option ....> configure....> Quick build -----> Xelatex + pdf i checked this one but it gives the error ! Fatal fontspec error: "cannot-use-pdftex" ! ! The fontspec package requires either XeTeX or LuaTeX to function. ! ! You must change your typesetting engine to, e.g., "xelatex" or "lualatex" What should i do now ? – Shaheryar Oct 4 '13 at 5:34

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.