Set a timer to remind yourself to go to lunch, then set a “get back to work” timer. You can set them on your phone as recurring alarms, so you don’t forget.
Also, is this something you’re actually at risk of doing (i.e. — you’ve actually done it or something like it while working)? Or are you just using it as an excuse?
As someone who religiously took lunch while working from home and during that time went for a walk and cooked my food fresh, it’s a lot harder than you think to just “forget” about the rest of your work day. In fact, the actual problem is usually the opposite — in order to “prove” you’re working, people tend to neglect everything else in favor of their job.
Nicole informed me that she eats lunch and takes a walk after lunch. I can add that to my list of “things I actually should start doing in order to preserve my sanity.”
So get out and do it. Go for a walk at the start of your lunch. Listen to a podcast or audio book if you want. When you get back, fix your lunch, eat it, and get back to work.