He had been the prime candidate for succession to the throne for the Whigs in the Exclusionist Crisis of 1679. After the fraud of the Popish Plot had been discovered, the real Rye House Plot of 1683 to assassinate both Charles II and James, the Duke of York forced Monmouth to leave England. When his father died, Monmouth invaded to wrest the crown from Catholic James II, landing at Lyme Regis and proclaiming himself "James II". After his capture, he was Attainted a traitor by Parliament and set for execution.
Unfortunately, executioners in England weren't what they had been. The Tudor monarchs had kept them in good practice and even knew where to get specialists for certain jobs (e.g., the swordsman from Calais for Anne Boleyn)--although there had been some shortages at times of practiced axemen because of issues of supply and demand (e.g., the inept execution of Blessed Margaret Pole at the Tower when there was so much to do in the north of England in the aftermath of the Pilgrimage of Grace). Jack Ketch was singularly inept and might have taken as many as EIGHT blows to sever Monmouth's head--the official count is FIVE. Poor Monmouth suffered horribly and his cries of agony were terrifying. Guards had to protect Ketch after the execution as the crowds were so enraged. And this after Monmouth had paid him in gold to do a good job, reminding him of the very bad job he'd done on Lord Russell after the Rye House Plot. Perhaps that reminder made him nervous.
Ketch was replaced as executioner for a time but recalled when his successor was hanged. (Gallows humor, anyone?)
James Scott was married, but following his father's example, was not faithful to his wife. Anne Scott, a wealthy Scottish heiress and he were married in 1663 and had eight children, four of whom survived infancy. His widow remarried: Charles Cornwallis, 3rd Baron Cornwallis. Monmouth also had children with his mistress, Eleanor Needham. In John Dryden's satiric and allegorical poem Absalom and Achitophel, Monmouth is Absalom, Charles II is King David, and Lord Shaftesbury, leader of the Exclusionist Whigs, is Achitophel.
Another important aspect of this story is that James II's army had many Roman Catholic officers. As he began his efforts to extend not just toleration but freedom of religion in England through his Declaration of Indulgence, James referenced the loyalty of these Catholic soldiers. He argued that their service should not be rewarded by the Test Act which would require their loss of rank and pay.