🧀 Learn Linux

Advanced · Let commands collaborate

tee: Output and save pipeline contents

Put in free practice

Syntax

tee [-a] [file…]

Options

-a
Additional content

Examples

grep ERROR logs/app.log | tee errors.txt

Usage and sandbox support

tee writes files and retains standard output at the same time, suitable for saving results in the middle of pipelines.

Hands-on exercises

Full documentation ↗

Related commands