No, they are not connected, but yes, they were meant to be loosely connected. They're officially different universes, with Spider-Man existing on Earth-96283, and the X-Men film series primarily occurring on Earth-10005 and Earth-17315, as well as a couple other universes, but only in minor scenes.
While this was planned, you have to keep in mind that it didn't happen. Same thing with the Fant4stic cast having a planned cameo in Deadpool 2 with released concept art.