The original context of "The cake is a lie" was to convey the message that a reward is being used to motivate Chell, the player character of Portal, without any intent of delivering.
[1] It can be found scribbled in an unhinged manner within hidden cubby-holes throughout the test chambers that players must complete, with the phrase written multiple times by the last surviving scientist of Aperture Science neurotoxin incident, Doug Rattman.
Portal writers Erik Wolpaw and Chet Faliszek developed the phrase as a plot device, "a thematic anchor that offers a chuckle or two in its setup, reveal, and post-credits wink" with no consideration given for its potential to become a viral phenomenon, as Wolpaw and Faliszek had anticipated that an innocuous hoop that falls from the sky after the player character escapes the exploding facility would catch on with fans instead.
[1] The idea of using cake as the proposed reward came about at the beginning of the Portal development process, where the writers convened as a group to determine which philosopher or school of philosophy their game would be based on.
[11] Stephen Totillo, who was an editor at MTV.com in 2008, attributed part of Portal's widespread acclaim to the phrase, along with its theme song, "Still Alive", and the Weighted Companion Cube.
[1] Amanda Brennan agreed and suggest that 2007 marked a point where internet culture transcended from niche forums such as 4chan and entered into "its own ecosystem", attaining mainstream appeal in the process.
[13] Usage of the phrase in popular culture experienced a resurgence in the year 2020 in response to the spread on social media of another cake-based meme, where it is used as a literal description of a hyper-realistic cake being made to look like something else.
[9] Conversely, The Escapist editor Ben "Yahtzee" Croshaw criticized the overuse of Internet memes, specifically mentioning the usage of the phrase as an easter egg reference in 'Splosion Man.
[32] Valve said that they intended to cease promotion of the catchphrase as humor that same year,[33] though an officially licensed cake mix for the Portal brand was created by German licensee Gaya Entertainment and released in 2013.