Skip to main content
Best answer

How to delete spreadsheet rows with date in the past

  • July 1, 2025
  • 6 replies
  • 30 views

I'm trying to create a Zap that runs daily and deletes all rows from a Google Sheet where the date (entered in column C) is in the past.
This is my current test setup, but it doesn't seem to be working correctly.

Step 2 transforms the start date into the previous day by subtracting 1 day.


I use this to compare it with the value in column C of the Google Sheet and, if they match, I delete the row using step 4.


Unfortunately, after a few days where it seemed to work, I now keep finding old rows still there.
Also, this "solution" only checks for today - 1 and doesn't delete rows with dates further in the past.

Does anyone have a solution?

Best answer by Troy Tessalone

@BoCcZzZ 

Also, info about using DateTime modifiers: 

 

You should add a Filter step between the GSheet steps to make sure the first GSheet step found rounds to delete, otherwise the second GSheet step will have an error.

Filter: https://zapier.com/apps/filter/integrations#help

 

You can check your Zap Run history to help you troubleshoot by viewing the DATA IN/OUT for each Zap step: https://zapier.com/app/history/

 

If you are trying to find all rows matching with a date before today, then that is different more advanced logic, which may involve using the GSheets API.

Zap action: GSheets - API Request

GSheets API: https://developers.google.com/workspace/sheets/api/guides/concepts

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

6 replies

Troy Tessalone
Zapier Orchestrator & Solution Partner
Forum|alt.badge.img+14
  • Zapier Orchestrator & Solution Partner
  • 34070 replies
  • July 1, 2025

Hi ​@BoCcZzZ 

For Zap step 2, instead of using AI by Zapier, use this action: Formatter > Date & Time > Format

Formatter steps count as 0 Tasks in Zap Runs.

 

For Zap step 3, how is this field configured? (screenshot)

 

How is your Zap step 4 configured? (screenshots)


  • Author
  • Beginner
  • 2 replies
  • July 1, 2025

Hi ​@Troy Tessalone Thank you!,
Step3:


Step4:

 


Troy Tessalone
Zapier Orchestrator & Solution Partner
Forum|alt.badge.img+14
  • Zapier Orchestrator & Solution Partner
  • 34070 replies
  • Answer
  • July 1, 2025

@BoCcZzZ 

Also, info about using DateTime modifiers: 

 

You should add a Filter step between the GSheet steps to make sure the first GSheet step found rounds to delete, otherwise the second GSheet step will have an error.

Filter: https://zapier.com/apps/filter/integrations#help

 

You can check your Zap Run history to help you troubleshoot by viewing the DATA IN/OUT for each Zap step: https://zapier.com/app/history/

 

If you are trying to find all rows matching with a date before today, then that is different more advanced logic, which may involve using the GSheets API.

Zap action: GSheets - API Request

GSheets API: https://developers.google.com/workspace/sheets/api/guides/concepts


JammerS
Forum|alt.badge.img+6
  • Zapier Staff
  • 3527 replies
  • July 2, 2025

Hi ​@BoCcZzZ,
 
We just wanted to see how everything is going with your Zap. Did Troy's recommendation get the job done? Feel free to reach out if you need further assistance with your Zap. We're glad to address any concerns and assist you.
 
We're looking forward to your response.


  • Author
  • Beginner
  • 2 replies
  • July 2, 2025

thank you ​@Troy Tessalone for your help!

I’ve applied the changes and I’m now monitoring the Zap.

 


SamB
Community Manager
Forum|alt.badge.img+11
  • Community Manager
  • 9736 replies
  • July 2, 2025

So glad Troy was able to help point you in the right direction here, ​@BoCcZzZ—nice work ​@Troy Tessalone! 🙌

Thanks so much for popping back in to mark Troy’s suggestion as the best answer, we really appreciate it.

Feel free to reach back out if you need help with anything else. In the meantime, happy Zapping! ⚡