It is easier to just buy 2 e-visas (you can buy a second one in advance if you are going to Afghanistan and will be without internet).
The teething issues seem to have mostly been ironed out: the site is working, and you get your e-visa e-mailed to you the next day.
Since June 3, 2016, anyone can apply for an e-visa to Tajikistan.The e-visa is valid at international airports and at land borders. The visa is valid for 45 days within a 90-day period from the entry date you fill in, and is single entry, just like the visa on arrival.If you want a double-entry visa, you will still need to visit an embassy.Make sure your details are correct when submitting, you cannot submit again without paying first.Citizens of Azerbaijan, Armenia, Belarus, Georgia, Kazakhstan, Kyrgyzstan, Moldova, Russia and Ukraine (90 days) do not need a visa to visit Tajikistan.
Holders of diplomatic or official/service passports of Brunei, China, Hungary, Iran, North Korea, Romania, South Korea and holders of diplomatic passports only of Afghanistan, Turkmenistan and Uzbekistan do not require a visa for Tajikistan.