diff --git a/Iceshrimp.Backend/Core/Database/Migrations/v2024.1-beta4/20240914004319_RemoveRemoteReplyNotifications.cs b/Iceshrimp.Backend/Core/Database/Migrations/v2024.1-beta4/20240914004319_RemoveRemoteReplyNotifications.cs
new file mode 100644
index 00000000..4566467a
--- /dev/null
+++ b/Iceshrimp.Backend/Core/Database/Migrations/v2024.1-beta4/20240914004319_RemoveRemoteReplyNotifications.cs
@@ -0,0 +1,27 @@
+using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Infrastructure;
+
+#nullable disable
+
+namespace Iceshrimp.Backend.Core.Database.Migrations
+{
+ ///
+ [DbContext(typeof(DatabaseContext))]
+ [Migration("20240914004319_RemoveRemoteReplyNotifications")]
+ public partial class RemoveRemoteReplyNotifications : Migration
+ {
+ ///
+ protected override void Up(MigrationBuilder migrationBuilder)
+ {
+ migrationBuilder.Sql("""
+ DELETE FROM "notification" WHERE "notifieeId" NOT IN (SELECT "id" FROM "user" WHERE "host" IS NULL);
+ """);
+ }
+
+ ///
+ protected override void Down(MigrationBuilder migrationBuilder)
+ {
+
+ }
+ }
+}