Upvote:7
Assuming it's on one ticket, you will go through customs only upon landing in Nepal and will not actually enter the UAE officially (you remain in a transit lounge).
In some situations you might have to also go through customs in the UAE, but in any case you definitely will be dealing with Nepalese customs.