Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

ralphmorris's avatar

Putting a comma into a url verses a query string - SEO

I have a search results page of users that is filtered down by their location and the services they provide. A user can provide multiple services with a manyToMany relationship.

What do you think is a better url structure for these search parameters from an SEO point of view?

Comma separated services using something like this.

return redirect()->route('profiles.search.results', ['location' => $request->location, 'service' => implode($request->services, ',')]);

Giving this url..

profiles/hampshire/service1,service2

Or a more common query string resulting in the following:

/profiles/hampshire?service%5B0%5D=service1&service%5B1%5D=service2

I would normally go for a query string but having an array in a $_GET parameter looks much harder to read to me with the encoding. Unless there is a way to stop it encoding?

Any advice/opinions appreciated.

0 likes
4 replies
zachleigh's avatar
Level 47

Are you looking at this from an SEO point of view (as in Google etc. being able to decipher your urls) or from a user point of view (as in the user understanding where they are in the app)?

If we're talking SEO, then honestly I don't know bu I'm guessing that Google can read arrays in query strings. Google doesn't typically hit search result pages though...

If we're talking usability for the user, I solve this by parsing the query and making it readable on the page rather than in the url. So if the query string is /profiles/hampshire?service%5B0%5D=service1&service%5B1%5D=service2 in app you could simply display "Applied Services: Service1 and Service2".

1 like
ralphmorris's avatar

Thanks all. I went for query strings as suggested.

Please or to participate in this conversation.