Electronegativity in atoms causally relates to polarity in molecules, as different electronegativities in different components of an asymmetrical molecule cause that molecule to be polar. However, electronegativity differences that are too great lead not to polar molecules, but to ionic bonds. Electronegativity differences also do not lead to polar molecules when they are fully symmetrical because the charges are balanced.
Polar molecules occur when one side of the molecules receives a greater share of the shared electron charges than the other. One common example is the water molecule. Oxygen has a stronger electronegativity than hydrogen, and the two hydrogen atoms are bonded at an angle less than 180 degrees to the oxygen atom. This creates an asymmetrical molecule with a greater net electron charge on the oxygen side. Another common molecule, carbon dioxide, is not polar, despite several similarities.
Carbon dioxide is composed of two oxygen atoms and one carbon atom. Carbon has a similar electronegativity to hydrogen, so both oxygen atoms receive a greater share of the shared electron charges than the carbon. However, the oxygen molecules are bonded on exactly opposite sides of the carbon atom, at 180 degrees, so their greater charges cancel each other, and the molecule as a whole is not polar.