Concentration by mass is defined as the mass of the solute divided by the total mass of the solution and multiplied by 100.
Parts per million (or ppm) is defined as miligrams of solute per liter of solution. The first think that stands out is that you must go from mass of solution, which is used in concentration by mass, to volume of solution, or vice versa.
This is done by using the solution's density, which is usually given to you or assumed to be equal to the density of water, #"1 g/cm"^3#.
Here's an example of how you'd calculate concentration by mass using ppm. Let's assume you have #"1.0 L"# of a #"1.0 M"# #"NaCl"# solution and you want to know what is the concentration by mass in ppm of the #"Na"^(+)# ion. Since
#NaCl_((aq)) -> Na_((aq))^(+) + Cl_((aq))^(-)#
you know that you have a #1:1# mole ratio between #"NaCl"# and #"Na"^(+)#, which means that the number of #"Na"^(+)# moles will be equal to the number of #"NaCl"# moles. #"1.0 M"# in #"1.0 L"# means that
#C = n/V => n_("NaCl") = C * V = 1.0 * 1.0 = "1.0 moles NaCl"#
#"1.0 moles NaCl" * ("1 mole Na"^(+))/("1 mole NaCl") = "1.0 moles Na"^(+)#
This will get you to determine how many grams of #"Na"^(+)# ions you have
#"1.0 moles Na"^(+) * ("23.0 g")/("1 mole Na"^(+)) = "23 g Na"^(+)#
Now, the density of a #"1.0 M"# #"NaCl"# solution is about #"1.05 g/mL"#. This means that your solution weighs
#m_("solution") = V * rho = "1000 mL" * "1.05 g/mL" = "1050 g"#
Thus, the concentration by mass of the #"Na"^(+)# ion will be
#"%m" = ("23 g")/("1050 g") * 100 = 2.2%#
For ppm, you must go from grams to miligrams for the solute
#("23000 mg")/("1.0 L") = "23000 ppm Na"^(+)#