Choose the cooking method that works for you—boiling, roasting, or grilling.

On the grill

For charred, smoky corn on the cob, preheat a gas or charcoal grill to medium-high (pushing hot coals to one side of the grill). Pull back the husks and silks and remove the silks. Pull the husks together to form a handle and secure it with a strip of husk tied into a knot. Coat the corn with cooking spray and place on the lit side of the grill (with the husks hanging over the edge) until charred, 15 to 18 minutes. Remove the corn from the grill and wrap each ear (excluding the husks) individually in aluminum foil, placing two pats of butter in each foil packet. Keep warm until ready to serve.

In the oven

Oven-roasted corn on the cob takes a little longer to make than corn on the grill or the stovetop, but it's virtually hands-off. Start by making a flavored butter by combining minced fresh herbs (like parsley, rosemary, and thyme), minced garlic, and salt and pepper with softened unsalted butter. Spread a tablespoon of butter over each cob, then wrap individually in aluminum foil. Place the foil-wrapped corn on a baking sheet and bake in a 425˚F oven for 20 to 25 minutes, turning once halfway through the cook time. Remove from the foil and serve.

On the stovetop

As I wrote earlier, corn should not be boiled for more than a few minutes, especially if it's freshly picked. Place the cobs in a stockpot of rapidly boiling salted water for a minute, then remove them from the pot with tongs. This will keep the corn kernels juicy and crunchy but take the "raw" edge off.