The major influence on the value or price of a coin is the supply of that particular coin in a particular grade that is available for people to buy. The total possible supply available to the market is determined by the initial mintage of that coin. For most countries, at the end of a year, the coin dies with that year on it are destroyed and never used again. Hence, once a year is done the supply of that coin for that date is fixed (note: this does not take into account restrikes).
Many factors influence the demand for a particular type and/or date of coin. In the early 1900s coin boards became popular which greatly grew the coin collecting hobby in the United States. Additionally, marketing campaigns by coin dealers have also increased the demand for certain types of coins. For example, during the depression coin dealer B. Max Mehl advertised all over the country that he would pay $50 for any example of a 1913 Liberty Head Nickel. As a result, many people started collecting coins while they were looking for this valuable coin. In recent history, the 50 State Quarters Series by the U.S. Mint started all whole new generation of coin collectors. In 2009, the Lincoln cent was redesigned and many people became interested in collecting Lincoln cents again. All of these factors were in part responsible for increasing demand and driving up prices and values.
If a coin is made from a precious metal such as gold or silver, the intrinsic value of the metal contained within the coin can be a major factor in determining the value and price of it. In 1965 the United States began switching the composition of its dime, nickel, and half dollar from 90% silver to a base metal that consisted of copper and nickel. Therefore, well-worn U.S. coins dated 1964 and before are worth more for their silver content than they would be to a collector. Therefore, as the price of gold and silver rises and falls, so to can the prices and values of gold and silver coins rise and fall accordingly.
It goes without saying that coin collectors would like their coins to be in the finest condition possible: uncirculated. In order to obtain coins that look like they just came off the coining press at the mint, somebody must remove them from circulation and store them safely. In the early and mid-1800s, very few people collected coins in the United States and uncirculated examples are rare and more expensive. However, in the 1930s and 1950s coin collecting was popular and many people saved mint state specimens.
For example, the 1931-S Lincoln cent has a very low mintage yet an uncirculated coin does not sell for much more than a circulated specimen. This is because many people in 1931 started to hoard uncirculated rolls of these coins because they heard that the mintage was very low. If the reverse is true, (i.e. there are many circulated coins and very few uncirculated coins) then the circulated coins will be inexpensive and the uncirculated coins will be more expensive. This is also known as grade or condition rarities.
Finally, value and price of a coin can be influenced by the amount of inventory a particular dealer has on hand. For example, if a dealer has lots of 1931-S uncirculated Lincoln cents in his inventory, he will be more likely to reduce the price in order to sell more of them to collectors and reduce his inventory. On the other hand, if you are trying to sell a 1931-S uncirculated Lincoln cent to the same dealer, he will most likely offer you a value that is lower than what you would expect because he already has more than he needs in inventory. The reverse is true if he has very few coins in inventory. Therefore get several quotes from different coin dealers before you sell your coins.