We try not to get hung up on questions like whether or not to call light 'matter' or not. Light has energy and momentum, it exerts a gravitational pull on other things, etc. so it has a lot of the properties of the more ordinary stuff that gets called matter. On the other hand, you can view light as consisting of particles called photons, and a photon has no rest mass. That's the mass a particle has as viewed by somebody who says the particle isn't moving. Light is moving with respect to everybody. So in that way it differs from ordinary matter.