# Milliliters to Milligrams

**Formula:**`mass = volume × density`

## Introduction to Milliliters to Milligrams Conversion

The conversion from milliliters to milligrams is determined by the density of the substance. The formula ** mass** represents the weight in milligrams,

**represents the volume in milliliters, and**

*volume***represents the density of the substance in mg/mL. The result is expressed in milligrams.**

*density*## Parameter usage:

`volume`

= volume in milliliters`density`

= density in milligrams per milliliter (mg/mL)

## Example valid values:

`volume`

= 30`density`

= 2

## Output:

`mass`

= weight in milligrams

## Data validation

The volume and density must be greater than zero for a valid conversion.

## Summary

This converter provides a direct conversion from milliliters to milligrams based on the given density, applicable to various substances and solutions measured in milliliters and milligrams.

Tags: Unit Conversion, Milliliters, Milligrams, Density