Basically you need enough insurance to leave your dependents in the same position as if you were alive
This means calculating how much income the family will lose (your income, etc), how much they will gain (widow's pensions?, how much expenses will reduce (no mortgage payments, less travel cost?,...) how much expenses will increase (increased child care?,...) to calculate the shortfall in income and then multiply that by the number of years to cover - say until the children are adult?
These will be an amount - less whatever other life insurance or death in service might be paid out on your death