Printing gridlines isn't currently possible in Excel for the web. You can, however, print gridlines in the Excel desktop app.
-
To open the desktop app, select Editing and choose Open in Desktop App at the top of the ribbon.
Don't have the Excel desktop app? Try or buy Microsoft 365.
Or you can mimic gridlines by applying borders to the cells before printing.
-
Highlight cells to include and on the Home tab, select Borders (or press Ctrl+Shift+7) and choose All Borders.
Go to the Page Layout tab and select Print under Gridlines.
Tip: Clear the box to print without gridlines.