The people of those monarchies overthrowing them such as the French Revolution, which ironically was replaced by another monarchy.
Or even the government itself finding the monarchy unfit to lead to country which this is just hypothetical but when the British government was still a monarchy the Parliament could have overthrown the monarchy.
Andrew Jackson felt betrayed by his loss in 1824 and wanted to create a political party for the "common people" ... The spoils system was debated long after Jackson's presidency has ended.