How could the bitcoin protocol be changed? Has this ever occurred?

I keep coming across answers in questions on this site and on the wiki saying that the protocol might need to be changed in the future to create more scalability / security.

It seems to me that it is difficult to update the protocol now that there are so many different people involved and so much invested in the current protocol.

How could the bitcoin protocol be updated? Has this ever occurred to date?