Power Query: Rename Column Dynamically
Power BI
24. Juli 2026 06:12

Power Query: Rename Column Dynamically

von HubSite 365 über Wyn Hopkins [MVP]

Microsoft MVP | Author | Speaker | Power BI & Excel Developer & Instructor | Power Query & XLOOKUP | Purpose: Making life easier for people & improving the quality of information for decision makers

Microsoft expert guide to renaming columns in Power Query without references, Power BI and Excel training and tutorial

Key insights

  • Power Query editor
    Microsoft still treats column renames as a standard transform in the Power Query editor. Use the UI to rename or edit the M formula when you want a simple, manual change.
  • Table.RenameColumns
    A common hard-coded step is Table.RenameColumns(Source, {{"OldName","NewName"}}). That breaks if the source column name changes, so avoid embedding fixed old names when possible.
  • Table.ColumnNames + List.Zip
    Build a rename list from the current table’s column names and a target list, then pair them with List.Zip and apply Table.RenameColumns to rename dynamically.
  • mapping table
    Keep an external mapping table with OldColumn and NewColumn values to apply renames centrally. This makes renames reusable and easier to update across queries.
  • MissingField.Ignore
    Use MissingField.Ignore when applying renames so the query won’t fail if a source column is missing or already renamed. It improves resilience for changing schemas.
  • dynamic M code
    For durable solutions, write dynamic M code instead of hard-coding names: open the editor, derive current column names, build the rename mapping, and apply it. I can provide copy-paste M examples for general use, Power BI, or mapping-table approaches if you want.

Power BI - Power Query: Rename Column Dynamically

Keywords

Power Query rename column, rename column dynamically Power Query, M language rename column, Power BI rename column without referencing, rename column by position Power Query, Power Query change column name without reference, Power Query dynamic column renaming, Power Query rename columns programmatically