difference between cupcake and muffin

There might be some technical differences that a cook could tell us about, but from the consumer's point of view, the difference seems to be that a cupcake really is like a miniature cake: light in weight, sweet, and often covered with icing and decorations.

It tends to be not too tall because it's texture isn't strong enough to allow for a very tall structure. It's always made with white flour as far as I know. 

A muffin is significantly heavier in texture and also in weight; with its cohesiveness, it can contain fruit, nuts or chocolate chips, which are not common in cupcakes. 

It is never iced and need not be particularly sweet. It can be made with ingredients as heavy as bran, and can be rather tall and have a large overhanging rim that doesn't threaten to fall off. (The cupcake also has a rim, but it is rather delicate and not too large.) 

If you threw a cupcake against the wall, you would hear something of a "poof!" If you threw a muffin, you would hear a "thud!" 

A muffin goes with coffee, a cupcake with tea. (That's a rather controversial statement, so perhaps this discussion should be moved to the controversial topics zone.) 

Sociologically, a muffin is everyday living, whereas a cupcake is "we're getting fancy." 

Theoretically, a man could say, "hey honey" to his waitress while he was chewing on a muffin, but with cupcake in his mouth he could only say, "my dear." 

If you were writing a novel, it would be a gross literary error to substitute a cupcake for a muffin.