Editing Cells
VisiData supports direct cell editing, row insertion, deletion, and clipboard operations — making it a lightweight data entry and cleaning tool, not just a read-only viewer.
Understand the edit lifecycle: enter edit mode (e), modify, accept or cancel, then optionally save (Ctrl+S). Nothing is written to disk unless you explicitly save.
VisiData tracks modifications in memory only. Your source file is unchanged until you press Ctrl+S and confirm overwrite or provide a new filename.
Editing a Cell
e enter edit mode on current cell
ge <text> set current column for all selected rows to <text>
^O open current cell in external $EDITOR (e.g., vim)
g^O open current column for selected rows in external $EDITOR
Inside Edit Mode
Enter accept the edit
Ctrl+C cancel and discard the edit
Ctrl+A go to beginning of edit field
Ctrl+E go to end of edit field
Ctrl+K clear from cursor to end of line
Ctrl+U clear from cursor to beginning of line
^R reload initial value (discard typed content)
Tab accept edit and move cursor right
Shift+Tab accept edit and move cursor left
Up / Down accept edit and use previous/next history value
Renaming Columns
^ rename current column (opens input)
g^ rename all unnamed visible columns to current row contents
z^ rename current column to contents of current cell
Adding and Deleting Rows
a append a new blank row (after current)
za append a new blank column
ga <N> append N blank rows
gza <N> append N blank columns
d delete current row
gd delete all selected rows
gd immediately deletes all selected rows. There is no confirmation unless --quitguard is enabled. Use undo (U) to recover.
Undo and Redo
U undo most recent modification (requires undo enabled)
R redo the most recent undo
Enable undo in .visidatarc:
options.undo = True
Clipboard Operations
y yank (copy) current row to clipboard
gy yank all selected rows to clipboard
x cut (copy + delete) current row
gx cut all selected rows
p paste clipboard rows after current row
P paste clipboard rows before current row
# Column-specific clipboard
zy yank current column value for current row
gzy yank current column values for all selected rows
zp paste clipboard value into current column for current row
gzp paste into current column for all selected rows
# System clipboard (requires xclip or xsel)
Y yank current row to system clipboard
gY yank all selected rows to system clipboard
zY yank current column value to system clipboard
Fill Null Cells
f fill null cells in current column with the non-null value above
Useful for spreadsheets where a category cell only appears in the first row of a group.
Saving Changes
Ctrl+S save current sheet to file (prompts for filename)
g Ctrl+S save all sheets to files
z Ctrl+S save current column only
If you save back to the original file, VisiData will prompt for confirmation. Always use a new filename first if you are unsure.
Practical Use Cases
Fix a Typo in a Cell
vd /tmp/servers.csv
# Move cursor to the cell with the typo
e
# Backspace to remove typo, type correct value
Enter
# Save the fixed file
Ctrl+S
# Enter: /tmp/servers_fixed.csv
Bulk Set a Column Value
# Select all rows where region is 'sg'
|
# Enter: sg
# Set all selected rows' 'region' to 'Singapore'
ge
# Enter: Singapore
# Save
Ctrl+S
# Enter: /tmp/servers_updated.csv
Clean Null Values
vd /tmp/data.csv
# Move to column with null gaps
# Press f to fill nulls from above
f
# Verify, then save
Ctrl+S
# Enter: /tmp/data_cleaned.csv
Open a Cell in vim
# Move to a large text cell (e.g., error message)
^O
# Opens cell content in vim
# Edit, save and quit vim — cell is updated
Troubleshooting Matrix
| Problem | Cause | Fix |
|---|---|---|
| Edit mode opens immediately | Accidentally pressing e | Press Ctrl+C to cancel |
| Cannot save to original file | Permission denied | Use sudo vd or save to /tmp/ |
| Undo not working | options.undo is False | Enable in .visidatarc: options.undo = True |
ge sets wrong value | Wrong rows selected | Verify selection with Shift+S row count |
Hands-On Practice
cp /tmp/servers.csv /tmp/servers_edit.csv
vd /tmp/servers_edit.csv
# 1. Move to any cell, press e, change the value, press Enter
# 2. Press U to undo
# 3. Press a to add a blank row
# 4. Fill in the hostname cell with: testhost01
# 5. Press gd on a selected empty row to delete it
# 6. Press Ctrl+S → save as /tmp/servers_modified.csv