<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.10.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Swift",
  "identifier" : "/documentation/Swift/LosslessStringConvertible",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Swift"
    ],
    "preciseIdentifier" : "s:s25LosslessStringConvertibleP"
  },
  "title" : "LosslessStringConvertible"
}
-->

# LosslessStringConvertible

A type that can be represented as a string in a lossless, unambiguous way.

```
protocol LosslessStringConvertible : CustomStringConvertible
```

## Overview

For example, the integer value 1050 can be represented in its entirety as
the string “1050”.

The description property of a conforming type must be a value-preserving
representation of the original value. As such, it should be possible to
re-create an instance from its string representation.

## Relationships

### Conforming Types

[`Double`](/documentation/Swift/Double)

[`Bool`](/documentation/Swift/Bool)

[`Int16`](/documentation/Swift/Int16)

[`Int32`](/documentation/Swift/Int32)

[`Float80`](/documentation/Swift/Float80)

[`Int8`](/documentation/Swift/Int8)

[`Int128`](/documentation/Swift/Int128)

[`UInt32`](/documentation/Swift/UInt32)

[`Character`](/documentation/Swift/Character)

[`Float16`](/documentation/Swift/Float16)

[`Substring`](/documentation/Swift/Substring)

[`UInt8`](/documentation/Swift/UInt8)

[`UInt64`](/documentation/Swift/UInt64)

[`Int`](/documentation/Swift/Int)

[`Float`](/documentation/Swift/Float)

[`UInt16`](/documentation/Swift/UInt16)

[`Scalar`](/documentation/Swift/Unicode/Scalar)

[`UInt`](/documentation/Swift/UInt)

[`Int64`](/documentation/Swift/Int64)

[`UInt128`](/documentation/Swift/UInt128)

[`String`](/documentation/Swift/String)

### Inherited By

[`FixedWidthInteger`](/documentation/Swift/FixedWidthInteger)

[`StringProtocol`](/documentation/Swift/StringProtocol)

### Inherits From

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)