---
title: "SignalObject.Once"
description: "Subscribes a callback that runs once."
---

```lua
event:Once(callback: function): SignalConnection
```

---

## Aliases

- `SignalObject.once`

---

## Arguments

<ParamField body="callback" type="function" required>
  The callback to register. Keep the same function object for removal.
</ParamField>

---

## Returns

<ResponseField name="connection" type="SignalConnection">
  A custom connection that disconnects before its first callback.
</ResponseField>

The connection disconnects before its first invocation is scheduled, preventing another firing from scheduling it again.

**Related types:** [Signals types & behavior](/reference/signals/types) · [SignalObject](/reference/signals/signalobject).

---

## Example

```lua
local event = Signal.new()
local connection = event:Once(function(value) print(value) end)
event:Fire("first")
event:Fire("second")
task.wait()
print(connection.Connected)
```
