hg clone -r (parent1 of bad merge) -r (parent2 of bad merge) old new [extensions] hgext.mq= $ hg qimport -r changesetN:tip # This will add all of your changes since the merge to the queue $ hg qpop -a # This pops them all out of your history. $ hg strip changesetM # This removes the merge changeset. $ hg update -C default # Make sure we're on the default branch $ hg qpush -a # Take the changesets in the queue and push them back onto your history. $ hg qfinish -a # Remove changesets from the queue and finalize them as normal changesets.