Airflow Xcom Example ((full)) May 2026

Go to Task Instance → XCom tab → See key-value pairs.

Use return as a shortcut – return value auto-pushes to return_value key. airflow xcom example

3/4 ⚠️ Warning: XCom is NOT for large data (no CSVs, no models). Keep it under 48KB. Use S3/GCS for big files. Go to Task Instance → XCom tab → See key-value pairs

extract = PythonOperator( task_id='extract_order_task', python_callable=extract_order ) airflow xcom example

from airflow.operators.python import PythonOperator def push_func(ti): ti.xcom_push(key='result', value='hello_xcom')