I would say, "Мне нельзя" means some external restriction, most often - "I was forbidden", but also may be medical condition. It's not "I cannot", rather "I should not" or "I must not".
"Я не могу" is more general and may also mean "I'm not able for", or "I cannot" without specifying the reasons.
"Мне нельзя курить" sounds like a medical condition (I have an ulcer, I should not smoke), but may also be a restriction. "Я не могу курить" sounds really strange, like "I am not able to" (I tried, but I start caughing so badly I have to stop right away?).
I would not agree with Alexander that "нельзя" carries that "I want to" connotation internally, although it may widely be used that way (you don't want to refuse blatantly, so you refer to some external cause).