+++
# -----------------------------------------------------------------------
# Do not edit this file. It is automatically generated by API Documenter.
# -----------------------------------------------------------------------
title = "stringToMs"
keywords = ["grafana","documentation","sdk","@grafana/data"]
type = "docs"
+++
## stringToMs() function
### stringToMs() function
Signature
```typescript
export declare function stringToMs(str: string): number;
```
Import
```typescript
import { stringToMs } from '@grafana/data';
```
Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| str | string
| |
Returns:
`number`