diff --git a/app/controllers/securities_controller.py b/app/controllers/securities_controller.py
index <HASH>..<HASH> 100644
--- a/app/controllers/securities_controller.py
+++ b/app/controllers/securities_controller.py
@@ -115,10 +115,9 @@ def __get_model_for_details(
 
     # Profit/loss
     model.profit_loss = model.value - model.total_paid
-    if abs(model.value) > abs(model.total_paid):
-        model.profit_loss_perc = model.profit_loss * 100 / model.value
-    else:
-        model.profit_loss_perc = model.value * 100 / model.profit_loss
+    model.profit_loss_perc = abs(model.profit_loss) * 100 / model.total_paid
+    if abs(model.value) < abs(model.total_paid):
+        model.profit_loss_perc *= -1
     # Income
     model.income = sec_agg.get_income_total()
     model.income_perc = model.income * 100 / model.total_paid
correcting the unrealized gains/loss % calc