With the availability of internet, social media, etc., the interconnectedness of people within most societies has increased tremendously over the past decades. Across the same timespan, an increasing level of fragmentation of society into small isolated groups has been observed. With a simple model of a society, in which the dynamics of individual opinion formation is integrated with social balance, we show that these two phenomena might be tightly related. We identify a critical level of interconnectedness, above which society fragments into sub-communities that are internally cohesive and hostile towards other groups. This critical communication density necessarily exists in the presence of social balance, and arises from the underlying mathematical structure of a phase transition known from the theory of disordered magnets called spin glasses. We discuss the consequences of this phase transition for social fragmentation in society.