Earning repeated cards in chests will allow you to gather cards to upgrade them. To upgrade cards, go to “Card Collection”, tap on the the card you want to upgrade, and tap "Upgrade".
You will know which cards are ready to be upgraded when the cards count bar is green. Each upgrade will require a specific amount of gold.
As you increase the card's level, you will need more cards and gold to upgrade it.