Heat butter in a large, heavy bottom skillet over medium-low heat. Add onion, allowing to sweat for 4-5 minutes.
Add corn, continue to cook over medium-low heat for 30 minutes, stirring every 5 minutes to cook evenly. Corn and onions should start to lightly brown and caramelize.
Before serving, add agave nectar and salt, mixing to combine. Serve immediately