Can we hide an object but still appear when rendered?

Can we hide an object but still appear when rendered?
Working a scene in a room is often a pain in the...
The wall of a small room often hinders the view, when we moves around
So can we hide it but on the viewport but still make it visible on render?
Post edited by James on
Comments
Like so.