So I want to setup a messaging server in my home that works like Telegram or Whatsapp - it should use the local network as we plan on moving around a lot of photos and files between our devices for some projects

What should I use? XMPP? Or Matrix? Or is there something else that’s ideal for local networks?

Thanks!