Reduce memory usage in a session by limiting the amount of history that is remembered.

The Wolfram System saves previous inputs and outputs for later reference using %, In and Out. By default, every previous input and output is saved. You can save substantial amounts of memory in a Wolfram System session by limiting the number of previous expressions it remembers.

Reduce the amount of session history that is saved

Set the Wolfram System to save no history:

Previous evaluations are no longer available via %, In or Out:

Set the Wolfram System to remember the last two evaluations:

The previous two evaluations are available via %, In and Out, but not evaluations further back:

Restore saving session history

Return to saving all previous evaluations: