Yes. But just so you know the navigation system works well (I use it regularly) and has good functionality, options and route settings, but does not have real time traffic updates...that was short lived in the gen 3 as Mazda dropped the ball on that one. Unfortunately, the XM radio in the Mazda 3 (at least with my 2017) is also not equipped with the ability to pick up any additional options like traffic or weather...it only supports the basic satellite radio function. If real time traffic updates are important to you then you'll have to look for android/apple apps or a garmin with that function.
The caveat: I'm located in North America. If you are in another region the answer maybe different.