Praise be to Allah.
If the old coins are made of gold and are sold for gold, or they are made of silver and are sold for silver, then they must be equal in weight and the exchange must take place on the spot. If they are sold for something other than their own type, such as if gold is sold for silver or cash, or silver is sold for cash, then the exchange must take place in the same sitting, but it is not stipulated that they be equal in weight, because the Prophet (blessings and peace of Allah be upon him) said: “Gold for gold, silver for silver, wheat for wheat, barley for barley, dates for dates, salt for salt, like for like, same for same, hand to hand. But if these commodities differ, then sell as you like, as long as it is hand to hand.” Narrated by Muslim (2970), from the hadith of ‘Ubaadah ibn as-Saamit (may Allah be pleased with him).
It makes no difference in that regard whether the currency is used now or is not used, so long as it is made of gold or silver, which according to the religious texts are among the categories that are subject to riba (usury).
But if the currency is made of something other than gold or silver, such as if it is made of paper or copper and the like, and it is no longer in circulation and is no longer used to work out the prices of things, then the issue of riba no longer applies to it, and it has become a kind of trade good. In that case, it is permissible to buy it and sell it for whatever price the two parties to the transaction agree upon, provided there is no extravagance, because some people spend excessive amounts of money to buy these old coins, but Islamic teachings enjoin being careful with one’s wealth and forbid wasting it.
Shaykh Ibn ‘Uthaymeen (may Allah have mercy on him) was asked about selling old coins for more than their face value.
There is nothing wrong with that, because old currencies are no longer used as cash. So if, for example, someone has one of the early, red riyal notes, or a five-riyal note or a ten-riyal note that is no longer legal tender, and he wants to sell that ten-riyal note for one hundred riyals, there is nothing wrong with that, because now it has become an item for sale and is no longer currency, so there is nothing wrong with that. "Liqa’ al-Baab al-Maftooh (233/18)"
And Allah knows best.