---
title: GetPadding(Sprite)
product: Unity Editor
version: '7000.0'
latest_version: '7000.0'
status: This page documents version 7000.0. The latest version is 7000.0.
canonical: https://docs.unity.com/en-us/engine/7000.0/script-reference/unityengine/sprites/datautility/getpadding
latest_url: https://docs.unity.com/en-us/engine/7000.0/script-reference/unityengine/sprites/datautility/getpadding.md
last_updated: 2026-10-07
generated_at: 2026-11-11T06:28:42.850Z
locale: en-us
---

# GetPadding(Sprite)

> Return the padding on the sprite.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine.Sprites](/engine/7000.0/script-reference/unityengine/sprites.md)
* **Assembly:** UnityEngine.CoreModule

```csharp
public static Vector4 GetPadding(Sprite sprite)
```

### Parameters

**** (\[Sprite]\(/engine/7000.0/script-reference/unityengine/sprite)):&#x20;

### Returns

| Type                                                              | Description |
| ----------------------------------------------------------------- | ----------- |
| [Vector4](/engine/7000.0/script-reference/unityengine/vector4.md) |             |

### Remarks

If the sprite has been packed it is possible that edges have been cliped from the source sprite. This will give the edge clipped size in pixels for each edge (x=left, y=bottom, z=right, w=top).
