remove toolbar but only for front-end

Hello,

I would like to remove the toolbar for every users but only on the website. I want to keep on dashboard.

I m on a multisite configuration.

I know how to do with CSS but would like to do that properly and really remove with php code.

Is it possible to do that with a function and not css?

Thank you