Gmail query line: how to ask for unread incoming mail that is not in:spam

gmail

I'm looking for a filter that would look something like:

in:inbox in:unread not in:spam

Specifically, I'm looking for not in: syntax, but can't figure out how that might spell.

Please, help.

Best Answer

You proposed this:

in:inbox in:unread not in:spam

The first fix is that instead of the word no you use a "-". That means the syntax is:

in:inbox in:unread -in:spam

The second fix is that the -in:spam is not needed.

If a message/conversation has the inbox label then is doesn't have the spam label. Now if the "-in:spam" was just an example then your search will return all unread messages/conversations that have the inbox label but do not have the other label.