Question: There are two worlds of more or less equivalent technological level, say a difference of only a few decades and no more than 50 years. A first contact event occurs and after the hoopla dies down trading starts. 

Initially, barter is the primary form of trade but this quickly becomes cumbersome.

How would the two economies first establish a currency exchange and exchange rate?

Some commodities are similar and occur in similar quantities, particularly minerals gold, iron etc. Other commodities are unique to one civilization or the other; plants and animals unique to each planet, unique tech developed by one and not the other.

Some restrictions:

* Both planets have one currency or at least a dominant currency (like the USD)
* Neither planet is in a "dominant" economic or technological position.
* Travel between the planets takes a few days
* There is a moderate level of trust in business dealings but it is not clear how laws apply to off worlders on each planet.

Ideas I've toyed with:

* comparable commodity-based exchange, ie. gold standard type exchanges, but this seems archaic for technologically advanced worlds and would anyone really want to transport heavy gold out of the gravity well of a planet
* some type of crypto type exchange, but this seems problematic with distance and not very conducive to trade as the price fluctuates

Answer: 
Comparing commodities. Money, after all, is just an abstract representation of goods and services. The only reason any form of fiat currency has power is its ability to be swapped for either a good or a service. A way to get an idea at what the exchange rate would be is to just compare a common and frequently used commodity between the two and use it to set a benchmark.

The trick is finding the commodity. Any metal that's used in equal measure would be useful, but suppose one planet is iron-rich and the other is iron-poor? Or perhaps one culture values gold whereas the other values silver? If both planets have the same amount of metals and use similar ways to process it, that would be the best, but that's not always the case.

Services would actually be another good place to start. Figure out the 'living wage', as in how much money would be the bare minimum for living expenses i.e. food, clothing, shelter at a minimal level. Or plot a graph with the respective salaries for necessary jobs - like doctor, farmer, lawyer, etc. (Cue lawyer joke.) Take all that information together and you should get a pretty good idea of what the exchange rate should look like.
OK, let's think about it:

* we have roughly market economies on both sides
* we have not united planets with already non uniform jurisdiction => they must already have some rules governing [conflict of laws](https://en.wikipedia.org/wiki/Conflict_of_laws) or [law of the sea](https://en.wikipedia.org/wiki/Law_of_the_sea)
* we have modern states, which detest any power vacuum and just in case would impose (or even usurp) their authority on everything closing by. (not mentioning that modern states would quite quickly at least start to establish some kind of relationship and working on treaties)

So for practical purposes a space alien is a foreigner like any other, who while in your space is subject to local laws, but for many purposes concerning example technical certification of his ship is considered to be subject to his local laws, unless they are considered as outrageous. (In this case he is politely asked to comply with local laws or refused docking rights).

I don't think that any high tech tech civilisation would barter much. It would be too cumbersome. Rather an alien would check what he can buy, whether there are any nasty restrictions, and if everything is fine would accept local currency with tendency to err on side of caution. Moreover, someone presumably would even demand from him some cash payment for tariffs or docking fees. If he didn't trust it, then he would just try to spend it all before leaving those barbarians.

**Exchange rate would be determined by the market and it would happen very fast. However, at first it would jump a lot, before stabilising. In a while all major currencies of the other world would be honoured.**