Instructions
Play through the game and beat the Elite Four. Intentionally, leave at least two trainers unfought during the game. The objective continues no matter who the first trainer is, but the second should be one of the trainers west of Lavender Town. The second trainer must be the one who reacts to you from a distance or the glitch will not work.
Teach Fly, Surf and Dig to Pokemon and include all three moves within your party.
Obtain a Pokemon with a Special stat of 31, 32, 61, 62, 63, 67, 68, 69 or 86. Others will work, but higher stats are more difficult to obtain. Put it at the top of your Pokemon list.
Go to the first trainer and save the game before encountering him. Walk into his encounter range and press start. If done correctly, the menu appears before the trainer reacts. If done incorrectly, reset the game and try again. Use your Fly-capable Pokemon to fly to Lavender Town.
Head west from Lavender Town and encounter the second trainer from a distance so that he has to walk to you. If you walk in the space directly in front of him, the game freezes.
Fight the trainer normally and defeat him, then fly to Cerulean City. Use Surf to enter the Unknown Dungeon north of Cerulean and go to a part of the cave that has wild Ditto, running from all other Pokemon that you encounter.
Encounter a Ditto but not defeat it; allow it to use Transform (thus copying the Pokemon with the correct Special stat) and then run away from the battle. Use Dig to escape the Unknown Dungeon without encountering any other Pokemon, and then fly to Lavender Town.
Move whatever item that you wish to duplicate to the sixth slot of your inventory. Leave Lavender Town through the west exit and your menu pops up. Cancel out of the menu and a battle with a Missingno will start, allowing you to capture if you wish.