The patent, published on 8 March 2018 but filed on 8 September 2016, sets out two designs that would prevent "contaminants" from causing Macbook keys to get stuck.
The proposed designs could also see Apple keyboards become resistant to liquid spillages.
"Keyboards typically involve a number of moving keys," reads the patent, published by the US Patent and Trademark Office. "Liquid ingress around the keys into the keyboard can damage electronics."
"Residues from such liquid such as sugar, may corrode or block electrical contacts, prevent key movement by bonding moving parts and so on. Solid contaminants (such as dust, dirt, food crumbs, and like) may lodge under keys, blocking electrical contacts, getting in the way of key movement."
The patents outline the use of "brushes, wipers, or flaps" to block gaps around keys.
One solution creates a layered barrier between the keyboard and the inside of the computer, while another uses a "skirt" to protect the keyboard actuator from any liquid or dirt. Another would see crumbs forced out of the gaps as the user types, by "bellows" located underneath each key.
"Keyboards [could] include mechanisms that prevent and/or alleviate contaminant ingress," reads the patent.
"A keyboard assembly [could include] a substrate, a keycap, and a guard structure extending from the key cap that funnels contaminants away from the movement mechanism," it continues.
Apple's crumb-proof keyboard follows on from a patent it filed in 2016 for a customisable keyless keyboard, which would abandon traditional keys in favour of a "force-sensitive" sheet that could function like an oversized trackpad.
The company famously files large numbers of patents each year, many of which don't come to fruition. Others include a wireless headset that mounts an iPhone in front of the eyes and a retro-style flip phone with an OLED screen display.
Apple recently announced that this year's Worldwide Developer's Conference will be held from June 4 to 8. Apple blog Macrumours predicted the event will see the company reveal lower-priced Macbooks and new iPad Pro models equipped with Face ID, as well as iOS 12 and new software for its HomePod.
Apple featured at number 10 on Dezeen Hot List 2017. However, the tech company has recently been in the news for the wrong reasons with the HomePod speaker reportedly causing damage to wooden furniture, and having to face lawsuits following the revolution that it intentionally slowed down older iPhones.